mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-22 23:24:59 +00:00
Add XCore support for ATOMIC_FENCE.
ATOMIC_FENCE is lowered to a compiler barrier which is codegen only. There is no need to emit an instructions since the XCore provides sequential consistency. Original patch by Richard Osborne git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194464 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
16
test/CodeGen/XCore/atomic.ll
Normal file
16
test/CodeGen/XCore/atomic.ll
Normal file
@@ -0,0 +1,16 @@
|
||||
; RUN: llc < %s -march=xcore | FileCheck %s
|
||||
|
||||
; CHECK-LABEL: atomic_fence
|
||||
; CHECK: #MEMBARRIER
|
||||
; CHECK: #MEMBARRIER
|
||||
; CHECK: #MEMBARRIER
|
||||
; CHECK: #MEMBARRIER
|
||||
; CHECK: retsp 0
|
||||
define void @atomic_fence() nounwind {
|
||||
entry:
|
||||
fence acquire
|
||||
fence release
|
||||
fence acq_rel
|
||||
fence seq_cst
|
||||
ret void
|
||||
}
|
Reference in New Issue
Block a user