LWN.net Logo

A perf ABI fix

A perf ABI fix

Posted Sep 26, 2013 20:06 UTC (Thu) by pr1268 (subscriber, #24648)
In reply to: A perf ABI fix by geofft
Parent article: A perf ABI fix

Perhaps I shouldn't have said "Seriously"... My facetiousness extended to the second part of my original comment. Not to mention a typo: s/__uu64/__u64/. Of course, I could simply do a typedef __u64 __uu64; and voilà! Typo gone. :-D

I'm actually intrigued by the fact some above mention using bitfields is perhaps preferred to preprocessor macros. I was under the perception (based on my 2003-2005 undergraduate CS education) that they're frowned upon. As are unions. (Personally, I'm not bothered by either; I have used bitfields and unions, even very recently, in code I've written for demonstrating IEEE-754 floating point representation in binary. A quick look at /usr/include/ieee754.h will show lots of bitfields.)

P.S.1: Even COBOL has a union programming structure (the REDEFINES keyword).

P.S.2: I do think the Perf developers' solution is quite elegant. Well done, folks!


(Log in to post comments)

A perf ABI fix

Posted Sep 26, 2013 20:25 UTC (Thu) by ncm (subscriber, #165) [Link]

I despair.

Might such travesties have led Brian Kernighan to say that Linux kernel code was even worse than Microsoft NT kernel code he had seen?

At X.org, they take long-time brokenness of a feature to demonstrate that the feature is unused and may be eliminated. That would not be inappropriate in this case. If the feature is expected to be useful in the future, the sensible approach is to design another interface with another name, and leave the busted one the hell alone.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds