Daniel Sanders | 8008de5 | 2015-10-15 14:34:23 +0000 | [diff] [blame] | 1 | ; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mattr=mips16 -mattr=+soft-float -mips16-hard-float -relocation-model=static -mips16-constant-islands < %s | FileCheck %s -check-prefix=jal16 |
Reed Kotler | 2fc05be | 2013-11-21 05:13:23 +0000 | [diff] [blame] | 2 | |
| 3 | @j = global i32 10, align 4 |
| 4 | @.str = private unnamed_addr constant [11 x i8] c"at bottom\0A\00", align 1 |
| 5 | @i = common global i32 0, align 4 |
| 6 | |
| 7 | ; Function Attrs: nounwind |
| 8 | define i32 @main() #0 { |
| 9 | entry: |
| 10 | %retval = alloca i32, align 4 |
| 11 | store i32 0, i32* %retval |
| 12 | br label %z |
| 13 | |
| 14 | z: ; preds = %y, %entry |
| 15 | %call = call i32 bitcast (i32 (...)* @foo to i32 ()*)() |
| 16 | call void asm sideeffect ".space 10000000", ""() #2, !srcloc !1 |
| 17 | br label %y |
| 18 | |
| 19 | y: ; preds = %z |
David Blaikie | 23af648 | 2015-04-16 23:24:18 +0000 | [diff] [blame] | 20 | %call1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0)) |
Reed Kotler | 2fc05be | 2013-11-21 05:13:23 +0000 | [diff] [blame] | 21 | br label %z |
| 22 | |
| 23 | return: ; No predecessors! |
David Blaikie | a79ac14 | 2015-02-27 21:17:42 +0000 | [diff] [blame] | 24 | %0 = load i32, i32* %retval |
Reed Kotler | 2fc05be | 2013-11-21 05:13:23 +0000 | [diff] [blame] | 25 | ret i32 %0 |
| 26 | ; jal16: jal $BB{{[0-9]+}}_{{[0-9]+}} |
| 27 | } |
| 28 | |
| 29 | declare i32 @foo(...) #1 |
| 30 | |
| 31 | declare i32 @printf(i8*, ...) #1 |
| 32 | |
| 33 | attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" } |
| 34 | attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" } |
| 35 | attributes #2 = { nounwind } |
| 36 | |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 37 | !1 = !{i32 68} |