[LLVMdev] Proposal for better assertions in LLVM

Chris Lattner clattner at apple.com
Tue Aug 9 13:59:19 PDT 2011


On Aug 8, 2011, at 10:46 PM, Talin wrote:

> So I went ahead and implemented this in my own frontend - I've been using it for both assertions and conditional debug statements. I like it quite a bit, and like you say, it compiles down to nothing in non-debug builds.

Does:
   YOUR_DEBUG_MACRO(…) << some_out_of_line_function();

Still evaluate the out of line function?  If so, it seems that something like the LLVM "DEBUG" macro is a better approach.

-Chris



More information about the llvm-dev mailing list