2008-03-01 10:15:35 +01:00
|
|
|
; RUN: llvm-as < %s | opt -globalopt | llvm-dis | not grep global
|
2004-10-09 23:50:05 +02:00
|
|
|
|
2008-03-01 10:15:35 +01:00
|
|
|
@G = internal global void ()* null ; <void ()**> [#uses=2]
|
2004-10-09 23:50:05 +02:00
|
|
|
|
2008-03-01 10:15:35 +01:00
|
|
|
define internal void @Actual() {
|
|
|
|
ret void
|
2004-10-09 23:50:05 +02:00
|
|
|
}
|
|
|
|
|
2008-03-01 10:15:35 +01:00
|
|
|
define void @init() {
|
|
|
|
store void ()* @Actual, void ()** @G
|
|
|
|
ret void
|
2004-10-09 23:50:05 +02:00
|
|
|
}
|
|
|
|
|
2008-03-01 10:15:35 +01:00
|
|
|
define void @doit() {
|
|
|
|
%FP = load void ()** @G ; <void ()*> [#uses=1]
|
|
|
|
call void %FP( )
|
|
|
|
ret void
|
2004-10-09 23:50:05 +02:00
|
|
|
}
|
2008-03-01 10:15:35 +01:00
|
|
|
|