[LLVMbugs] [Bug 11495] New: int-to-vector bitcast can't be lowered

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Dec 6 15:33:47 PST 2011


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

             Bug #: 11495
           Summary: int-to-vector bitcast can't be lowered
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Common Code Generator Code
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: richard-llvm at metafoo.co.uk
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


The following code, when fed to clang...

typedef float __attribute__((__vector_size__(8))) vf;
vf v = (vf)0x123456789abcdef0ull;

... produces this IR (as of r145981, when I fixed a wrong-code bug for
big-endian systems on this code)...

; ModuleID = '-'
target datalayout =
"e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@v = global <2 x float> bitcast (<1 x i64> <i64 1311768467463790320> to <2 x
float>), align 8

The backend fails when fed this code (at -O0):

Unknown constant value to lower!
UNREACHABLE executed at lib/CodeGen/AsmPrinter/AsmPrinter.cpp:1441!
[...]

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