xref: /aosp_15_r20/external/llvm/test/CodeGen/X86/cmpxchg16b.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -march=x86-64 -mcpu=core2 | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker
3*9880d681SAndroid Build Coastguard Worker; Basic 128-bit cmpxchg
4*9880d681SAndroid Build Coastguard Workerdefine void @t1(i128* nocapture %p) nounwind ssp {
5*9880d681SAndroid Build Coastguard Workerentry:
6*9880d681SAndroid Build Coastguard Worker; CHECK: movl	$1, %ebx
7*9880d681SAndroid Build Coastguard Worker; CHECK: lock cmpxchg16b
8*9880d681SAndroid Build Coastguard Worker  %r = cmpxchg i128* %p, i128 0, i128 1 seq_cst seq_cst
9*9880d681SAndroid Build Coastguard Worker  ret void
10*9880d681SAndroid Build Coastguard Worker}
11*9880d681SAndroid Build Coastguard Worker
12*9880d681SAndroid Build Coastguard Worker; FIXME: Handle 128-bit atomicrmw/load atomic/store atomic
13