[LLVMbugs] [Bug 11570] New: boost karma causes clang optimizer crash

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Dec 14 10:35:56 PST 2011


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

             Bug #: 11570
           Summary: boost karma causes clang optimizer crash
           Product: clang
           Version: trunk
          Platform: Macintosh
        OS/Version: MacOS X
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: kyle.tarplee at numerica.us
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Created attachment 7727
  --> http://llvm.org/bugs/attachment.cgi?id=7727
the code that causes the crash

I have distilled the crash down to a simple one liner that causes the compiler
to fresh with the error


fatal error: error in backend: Cannot select: 0x7fa5b6abb210: i64 = shl
0x7fa5b6ae0c10, 0x7fa5b6ab7c10 [ID=23]
  0x7fa5b6ae0c10: i64 = fgetsign 0x7fa5b6ae0a10 [ID=21]
    0x7fa5b6ae0a10: f64,ch = CopyFromReg 0x7fa5b5b6c528, 0x7fa5b6ae0b10
[ORD=324] [ID=17]
      0x7fa5b6ae0b10: f64 = Register %vreg1 [ORD=324] [ID=1]
  0x7fa5b6ab7c10: i64 = Constant<63> [ID=16]

When the optimization (-0) is turned on.  Without optimization it compiles
fine.

To reproduce it:

CC=clang++
#Any boost seems to do it
BOOST_HDRS=/opt/local/include
#BOOST_HDRS=~/projs/boost/boost_1_45_0


echo "No optimization"
$CC -c -I$BOOST_HDRS test_karma.cpp

echo "With -O optimization (expected failure)"
$CC -c -O -I$BOOST_HDRS test_karma.cpp



The error happens on clang++ version 3.0 from apple and on llvm trunk (r146173)
and clang trunk (r146174).

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