2006-11-28 06:14:06 +00:00
|
|
|
; The cast in this testcase is not eliminable on a 32-bit target!
|
2008-03-01 09:15:35 +00:00
|
|
|
; RUN: llvm-as < %s | opt -instcombine | llvm-dis | grep inttoptr
|
2003-11-03 18:33:44 +00:00
|
|
|
|
2008-03-01 09:15:35 +00:00
|
|
|
target datalayout = "e-p:32:32"
|
2003-11-03 18:33:44 +00:00
|
|
|
|
2008-03-01 09:15:35 +00:00
|
|
|
declare void @foo(...)
|
2003-11-03 18:33:44 +00:00
|
|
|
|
2008-03-01 09:15:35 +00:00
|
|
|
define void @test(i64 %X) {
|
|
|
|
%Y = inttoptr i64 %X to i32* ; <i32*> [#uses=1]
|
|
|
|
call void (...)* @foo( i32* %Y )
|
|
|
|
ret void
|
2003-11-03 18:33:44 +00:00
|
|
|
}
|
2008-03-01 09:15:35 +00:00
|
|
|
|