[LLVMbugs] [Bug 13830] New: libprofile_rt.dll crashes in EdgeProfAtExitHandler with lli

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Sep 13 02:28:21 PDT 2012


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

             Bug #: 13830
           Summary: libprofile_rt.dll crashes in EdgeProfAtExitHandler
                    with lli
           Product: Runtime Libraries
           Version: trunk
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P
         Component: libprofile library
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: geek4civic at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Assume i.ll is generated with "opt -insert-edge-profiling -S" from
llvm/test/Analysis/Profiling.

$ lli.exe -load libprofile_rt.dll i.ll

JIT's atexit handler does not invoke EdgeProfAtExitHandler.
llvm_start_edge_profiling() in EdgeProfiling.c calls libc's atexit().

EdgeProfAtExitHandler is called on CRT's (not JIT's) exit handler.
Then @EdgeProfCounters in i.ll has been released by MemoryManager, to become
inaccessible.

I have confirmed this on Win32. I guess this might be hidden bug also on other
hosts.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list