[LLVMbugs] [Bug 19562] New: Lots of leaks caused by DBuilder.createForwardDecl() calls in CGDebugInfo

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Apr 25 11:02:25 PDT 2014


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

            Bug ID: 19562
           Summary: Lots of leaks caused by DBuilder.createForwardDecl()
                    calls in CGDebugInfo
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: LLVM Codegen
          Assignee: unassignedclangbugs at nondot.org
          Reporter: nicolasweber at gmx.de
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

LSan reports many leaks below DBuilder.createForwardDecl(). From what I
understand, MDNode::getTemporary() (called by DIBuilder::createForwardDecl())
is special in that it needs a call to MDNode::deleteTemporary() which the other
MDNode::get() functions don't need.

>From what I understand, this is usually called through
DIType::replaceAllUsesWith(). CGDebugInfo::finalize() does call
replaceAllUsesWith(), but only for types in ReplaceMap, and most callers of
createForwardDecl() don't put the result in ReplaceMap. I don't understand the
code well enough to say if that's the bug.

-- 
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/20140425/e23c66ac/attachment.html>


More information about the llvm-bugs mailing list