Home | History | Annotate | Download | only in Hexagon
      1 ; RUN: llc -hexagon-long-calls -march=hexagon -enable-save-restore-long=true < %s | FileCheck %s
      2 
      3 ; CHECK: call ##f1
      4 ; CHECK: jump ##__restore
      5 
      6 ; Function Attrs: minsize nounwind
      7 define i64 @f0(i32 %a0, i32 %a1) #0 {
      8 b0:
      9   %v0 = add nsw i32 %a0, 5
     10   %v1 = tail call i64 @f1(i32 %v0) #1
     11   %v2 = sext i32 %a1 to i64
     12   %v3 = add nsw i64 %v1, %v2
     13   ret i64 %v3
     14 }
     15 
     16 ; Function Attrs: minsize nounwind
     17 declare i64 @f1(i32) #0
     18 
     19 ; Function Attrs: nounwind
     20 define i64 @f2(i32 %a0, i32 %a1) #1 {
     21 b0:
     22   %v0 = add nsw i32 %a0, 5
     23   %v1 = tail call i64 @f1(i32 %v0) #1
     24   ret i64 %v1
     25 }
     26 
     27 ; Function Attrs: noreturn nounwind
     28 define i64 @f3(i32 %a0, i32 %a1) #2 {
     29 b0:
     30   %v0 = add nsw i32 %a0, 5
     31   %v1 = tail call i64 @f4(i32 %v0) #2
     32   unreachable
     33 }
     34 
     35 ; Function Attrs: noreturn
     36 declare i64 @f4(i32) #3
     37 
     38 attributes #0 = { minsize nounwind }
     39 attributes #1 = { nounwind }
     40 attributes #2 = { noreturn nounwind }
     41 attributes #3 = { noreturn }
     42