bolt/deps/llvm-18.1.8/llvm/test/Transforms/AtomicExpand/X86/expand-atomic-rmw-initial-load.ll

12 lines
420 B
LLVM
Raw Normal View History

2025-02-14 19:21:04 +01:00
; RUN: opt -S %s -atomic-expand -mtriple=i686-linux-gnu | FileCheck %s
; This file tests the function `llvm::expandAtomicRMWToCmpXchg`.
; It isn't technically target specific, but is exposed through a pass that is.
define i8 @test_initial_load(ptr %ptr, i8 %value) {
%res = atomicrmw nand ptr %ptr, i8 %value seq_cst
ret i8 %res
}
; CHECK-LABEL: @test_initial_load
; CHECK-NEXT: %1 = load i8, ptr %ptr, align 1