Home | History | Annotate | Download | only in Hexagon
      1 ; RUN: llc -march=hexagon -print-machineinstrs=expand-isel-pseudos -o /dev/null 2>&1 < %s | FileCheck %s
      2 ; REQUIRES: asserts
      3 
      4 ; CHECK: J2_call @f1
      5 ; CHECK: PS_call_nr @f2
      6 
      7 target triple = "hexagon"
      8 
      9 @g0 = external global i32
     10 
     11 ; Function Attrs: nounwind
     12 define i32 @f0() #0 {
     13 b0:
     14   %v0 = load i32, i32* @g0, align 4
     15   %v1 = tail call i32 @f1(i32 %v0) #0
     16   %v2 = icmp eq i32 %v1, 0
     17   br i1 %v2, label %b1, label %b2
     18 
     19 b1:                                               ; preds = %b0
     20   tail call void @f2() #2
     21   unreachable
     22 
     23 b2:                                               ; preds = %b0
     24   ret i32 0
     25 }
     26 
     27 declare i32 @f1(i32)
     28 
     29 ; Function Attrs: noreturn
     30 declare void @f2() #1
     31 
     32 attributes #0 = { nounwind "disable-tail-calls"="true" }
     33 attributes #1 = { noreturn }
     34 attributes #2 = { noreturn nounwind }
     35