aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/ARM/atomic-cmp.ll
blob: a4738077b1a1d45374b4f7b0fc8c96c0e972d30f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
; RUN: llc < %s -mtriple=armv7-apple-darwin -verify-machineinstrs   | FileCheck %s -check-prefix=ARM
; RUN: llc < %s -mtriple=thumbv7-apple-darwin -verify-machineinstrs | FileCheck %s -check-prefix=T2
; rdar://8964854

define i8 @t(i8* %a, i8 %b, i8 %c) nounwind {
; ARM-LABEL: t:
; ARM: ldrexb
; ARM: strexb

; T2-LABEL: t:
; T2: ldrexb
; T2: strexb
  %tmp0 = cmpxchg i8* %a, i8 %b, i8 %c monotonic monotonic
  ret i8 %tmp0
}