[LLVMbugs] [Bug 5471] New: infinite loop with InstCombine

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Wed Nov 11 16:52:22 PST 2009


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

           Summary: infinite loop with InstCombine
           Product: libraries
           Version: trunk
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Scalar Optimizations
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: alexmac at adobe.com
                CC: llvmbugs at cs.uiuc.edu


If you have some mismatched calling conventions you can get the InstCombine
pass into an infinite loop. This took me a while to track down so it would be
good if we could fix this, or assert, so that others don't fall into the same
trap.

Here is a minimal bit of code that repros the problem. The invoke instruction
should be marked with the correct calling convention, but it is not.
InstCombine then gets into a loop adding and removing the redundant store inst.

// ----------------------------------------------------
define arm_apcscc i32 @func2() {
        ret i32 0
}

define arm_apcscc void @brokenfunc() {
        store i1 true, i1* undef
        %1 = invoke i32 @func2() to label %exit unwind label %exit
exit:
        ret void
}
// ----------------------------------------------------


Please let me know what you think the best thing to do is.


-- 
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