2008-02-15 23:58:25 +00:00
|
|
|
; RUN: llvm-as < %s | llvm-dis | not grep ptrtoint
|
2014-08-19 21:08:27 +00:00
|
|
|
; RUN: verify-uselistorder %s
|
2004-03-08 06:17:15 +00:00
|
|
|
; All of these should be eliminable
|
|
|
|
|
|
|
|
|
2008-02-15 23:58:25 +00:00
|
|
|
define i32 @foo() {
|
|
|
|
ret i32 and (i32 ptrtoint (i32()* @foo to i32), i32 1)
|
2004-03-08 06:17:15 +00:00
|
|
|
}
|
|
|
|
|
2008-02-15 23:58:25 +00:00
|
|
|
define i32 @foo2() {
|
|
|
|
ret i32 and (i32 1, i32 ptrtoint (i32()* @foo2 to i32))
|
2004-03-08 06:17:15 +00:00
|
|
|
}
|
|
|
|
|
2008-02-15 23:58:25 +00:00
|
|
|
define i1 @foo3() {
|
|
|
|
ret i1 icmp ne (i1()* @foo3, i1()* null)
|
2004-03-08 06:17:15 +00:00
|
|
|
}
|