https://llvm.org/bugs/show_bug.cgi?id=26992

            Bug ID: 26992
           Summary: instcombine attempts to insert in catchswitch
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedb...@nondot.org
          Reporter: andrew.kay...@intel.com
                CC: llvm-bugs@lists.llvm.org
    Classification: Unclassified

Created attachment 16051
  --> https://llvm.org/bugs/attachment.cgi?id=16051&action=edit
Small reproducer

There is a scenario where instcombine will attempt to insert a rewritten GEP
instruction for a compare into a catchswitch block below the catchswitch
instruction.

I came across this in a program that was using the basic_istream template from
an MSVC header, but I have reduced the failure to the attached IR file.

The bad insertion is happening within the rewriteGEPAsOffset() function in
InstCombineCompares.cpp.

It looks like this problem was introduced with r257897.

I am able to reproduce the failure with the following command line:

opt -instcombine -S instcombine-badinsert.ll

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to