mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-01 05:01:59 +01:00
69fde521b5
We currently emit a serialization operation (bcr 14, 0) before every atomic load and after every atomic store. This is overly conservative. The SystemZ architecture actually does not require any serialization for atomic loads, and a serialization after an atomic store only if we need to enforce sequential consistency. This is what other compilers for the platform implement as well. llvm-svn: 310093
12 lines
246 B
LLVM
12 lines
246 B
LLVM
; Test 64-bit atomic loads.
|
|
;
|
|
; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
|
|
|
|
define i64 @f1(i64 *%src) {
|
|
; CHECK-LABEL: f1:
|
|
; CHECK: lg %r2, 0(%r2)
|
|
; CHECK: br %r14
|
|
%val = load atomic i64 , i64 *%src seq_cst, align 8
|
|
ret i64 %val
|
|
}
|