Month: June 2013

  • Integer Undefined Behavior Detection using Clang 3.3

    Undefined behaviors in C/C++ are harmful to developers: There are many kinds of undefined behavior They can be hard to understand Their effect changes depending on which compiler version you use, which compiler options you use, and they get worse every time an optimizer gets smarter Plenty of them aren’t reliably detected by any tool…

  • Type Punning, Strict Aliasing, and Optimization

    One of the basic jobs of a low-level programming language like C or C++ is to make it easy to peek and poke at data representations, as opposed to providing opaque high-level abstractions. Access to representations supports grungy tasks such as JIT compiling, setting up page tables, driving peripherals, and communicating with machines that use…

  • Funniest Computer Book?

    The other day Eric Eide noticed The UNIX Hater’s Handbook on my desk and remarked that there aren’t enough funny computer books. This is undeniably true. So now I’m trying to find the funniest computer book and I’d appreciate some help. Here are a few guidelines: Not really looking for a Dilbert collection. Let’s just…