Home | History | Annotate | Download | only in PowerPC
      1 ; RUN: llc < %s -march=ppc32 | FileCheck %s
      2 ; RUN: llc < %s -march=ppc64 -mcpu=a2 | FileCheck %s
      3 ; RUN: llc < %s -march=ppc32 -mcpu=440 | FileCheck %s -check-prefix=BE-CHK
      4 
      5 define i32 @has_a_fence(i32 %a, i32 %b) nounwind {
      6 entry:
      7   fence acquire
      8   %cond = icmp eq i32 %a, %b
      9   br i1 %cond, label %IfEqual, label %IfUnequal
     10 
     11 IfEqual:
     12   fence release
     13 ; CHECK: sync
     14 ; CHECK-NOT: msync
     15 ; BE-CHK: msync
     16   br label %end
     17 
     18 IfUnequal:
     19   fence release
     20 ; CHECK: sync
     21 ; CHECK-NOT: msync
     22 ; BE-CHK: msync
     23   ret i32 0
     24 
     25 end:
     26   ret i32 1
     27 }
     28 
     29