[LLVMbugs] [Bug 16195] New: DIBuilder::createLexicalBlock non-deterministic output

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sun Jun 2 12:27:19 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=16195

            Bug ID: 16195
           Summary: DIBuilder::createLexicalBlock non-deterministic output
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Core LLVM classes
          Assignee: unassignedbugs at nondot.org
          Reporter: clemahieu at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

DIBuilder::createLexicalBlock in DIBuilder.cpp:1098

Given the same module compiled in separate LLVMContext instances,
DIBuilder::createLexicalBlock generates different output and debug information.
 This makes regression testing for a front-end difficult since output changes
depending on how the LLVM library was used, even with unique contexts.

createLexicalBlock uses a static variable to generate a unique id:
  static unsigned int unique_id = 0;

I recommend moving this static variable out of the function and in to the
LLVMContext.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130602/d9316e96/attachment.html>


More information about the llvm-bugs mailing list