annotate test/Linker/link-arm-and-thumb.ll @ 146:3fc4d5c3e21e

set tail call flag for code segment in CGCAll
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sun, 23 Dec 2018 19:23:36 +0900
parents 803732b1fca8
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
121
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
1 ; RUN: llvm-as %s -o %t1.bc
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
2 ; RUN: llvm-as %p/Inputs/thumb.ll -o %t2.bc
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
3 ; RUN: llvm-link %t1.bc %t2.bc -S 2> %t3.out | FileCheck %s
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
4 ; RUN: FileCheck --allow-empty --input-file %t3.out --check-prefix STDERR %s
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
5
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
6 target triple = "armv7-linux-gnueabihf"
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
7
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
8 declare i32 @foo(i32 %a, i32 %b);
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
9
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
10 define i32 @main() {
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
11 entry:
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
12 %add = call i32 @foo(i32 10, i32 20)
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
13 ret i32 %add
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
14 }
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
15
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
16 ; CHECK: define i32 @main() {
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
17 ; CHECK: define i32 @foo(i32 %a, i32 %b) [[ARM_ATTRS:#[0-9]+]]
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
18 ; CHECK: define i32 @bar(i32 %a, i32 %b) [[THUMB_ATTRS:#[0-9]+]]
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
19
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
20 ; CHECK: attributes [[ARM_ATTRS]] = { "target-features"="-thumb-mode" }
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
21 ; CHECK: attributes [[THUMB_ATTRS]] = { "target-features"="+thumb-mode" }
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
22
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
23 ; STDERR-NOT: warning: Linking two modules of different target triples: