blob: 32ece8b9f07be4ffa4d4fd385a21072d1758115c [file] [log] [blame]
Dan Gohmanc8054d92009-09-09 00:09:15 +00001; RUN: llc < %s
Dan Gohman2fe43522008-07-30 18:36:51 +00002; PR2612
3
4@current_foo = internal global { } zeroinitializer
5
6define i32 @foo() {
7entry:
8 %retval = alloca i32
9 store i32 0, i32* %retval
10 %local_foo = alloca { }
David Blaikiea79ac142015-02-27 21:17:42 +000011 load { }, { }* @current_foo
Dan Gohman2fe43522008-07-30 18:36:51 +000012 store { } %0, { }* %local_foo
13 br label %return
14
15return:
David Blaikiea79ac142015-02-27 21:17:42 +000016 load i32, i32* %retval
Dan Gohman2fe43522008-07-30 18:36:51 +000017 ret i32 %1
18}