[LLVMbugs] [Bug 2375] New: llc crashes with initializer with bitcast of struct

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Tue May 27 02:48:42 PDT 2008


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

           Summary: llc crashes with initializer with bitcast of struct
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: sharparrow1 at yahoo.com
                CC: llvmbugs at cs.uiuc.edu


Created an attachment (id=1671)
 --> (http://llvm.org/bugs/attachment.cgi?id=1671)
Patch

Bug per description; testcase:

; ModuleID = '-'
target datalayout =
"e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128"
target triple = "i686-pc-linux-gnu"
        %union.anon = type [8 x i8]
@x = global %union.anon bitcast ({ i64 } { i64 4 } to %union.anon)

llc currently crashes trying to emit this initializer:
void llvm::AsmPrinter::printDataDirective(const llvm::Type*): Assertion `0 &&
"Can't handle printing this type of thing"' failed.

Fortunately, this is really easy to fix; patch attached.


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