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

           Summary: simplifycfg won't simplify switch to identical blocks
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: new bugs
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]
                CC: [email protected]


Given a branch where the two target blocks are identical ("ret i32 %b" in
both), simplifycfg will simplify them away. But not so for a switch statement:

define i32 @f(i32 %a, i32 %b) nounwind readnone {
entry:
        switch i32 %a, label %bb3 [
                i32 4, label %bb
                i32 6, label %bb
        ]

bb:             ; preds = %entry, %entry
        ret i32 %b

bb3:            ; preds = %entry
        ret i32 %b
}


-- 
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to