[llvm-bugs] [Bug 26992] New: instcombine attempts to insert in catchswitch

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Mar 18 16:37:39 PDT 2016


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: unassignedbugs at nondot.org
          Reporter: andrew.kaylor at intel.com
                CC: llvm-bugs at 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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160318/98e4ef37/attachment-0001.html>


More information about the llvm-bugs mailing list