blob: 885700ef82a5338d374760bdcdb3feffb607b26b [file] [log] [blame]
Evan Cheng933b5062008-06-12 21:23:38 +00001; RUN: llvm-as < %s | llc -march=x86 -mtriple=i386-linux | grep {(\$bar)} | count 1
2; RUN: llvm-as < %s | llc -march=x86 -mtriple=i386-linux | grep {(\$qux)} | count 1
3; RUN: llvm-as < %s | llc -march=x86 -mtriple=i386-linux | grep {(\$hen)} | count 1
Dan Gohman330ce442007-04-26 21:04:39 +00004; PR1339
5
6@"$bar" = global i32 zeroinitializer
7@"$qux" = external global i32
8
Evan Cheng933b5062008-06-12 21:23:38 +00009define i32 @"$foo"() nounwind {
Dan Gohman330ce442007-04-26 21:04:39 +000010 %m = load i32* @"$bar"
11 %n = load i32* @"$qux"
12 %t = add i32 %m, %n
13 %u = call i32 @"$hen"(i32 %t)
14 ret i32 %u
15}
16
17declare i32 @"$hen"(i32 %a)