2009-09-12 02:01:28 +08:00
|
|
|
; RUN: opt < %s -instcombine -S | grep icmp
|
2007-09-21 02:56:24 +08:00
|
|
|
; PR1678
|
|
|
|
|
2015-09-11 11:22:04 +08:00
|
|
|
@A = weak alias void (), void ()* @B ; <void ()*> [#uses=1]
|
2007-09-21 02:56:24 +08:00
|
|
|
|
2014-03-13 04:15:49 +08:00
|
|
|
define weak void @B() {
|
|
|
|
ret void
|
|
|
|
}
|
2007-09-21 02:56:24 +08:00
|
|
|
|
|
|
|
define i32 @active() {
|
|
|
|
entry:
|
|
|
|
%"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0]
|
|
|
|
%tmp1 = icmp ne void ()* @A, null ; <i1> [#uses=1]
|
|
|
|
%tmp12 = zext i1 %tmp1 to i32 ; <i32> [#uses=1]
|
|
|
|
ret i32 %tmp12
|
|
|
|
}
|