2013-03-06 08:17:04 +08:00
|
|
|
; RUN: llc < %s -mtriple=i686-none-linux -verify-machineinstrs | FileCheck %s
|
2012-08-18 07:24:29 +08:00
|
|
|
|
|
|
|
define i32* @test_atomic_ptr_load(i32** %a0) {
|
|
|
|
; CHECK: test_atomic_ptr_load
|
|
|
|
; CHECK: movl
|
|
|
|
; CHECK: movl
|
|
|
|
; CHECK: ret
|
|
|
|
0:
|
2015-02-28 05:17:42 +08:00
|
|
|
%0 = load atomic i32*, i32** %a0 seq_cst, align 4
|
2012-08-18 07:24:29 +08:00
|
|
|
ret i32* %0
|
|
|
|
}
|
|
|
|
|
|
|
|
define void @test_atomic_ptr_store(i32* %a0, i32** %a1) {
|
|
|
|
; CHECK: test_atomic_ptr_store
|
|
|
|
; CHECK: movl
|
|
|
|
; CHECK: movl
|
|
|
|
; CHECK: xchgl
|
|
|
|
; CHECK: ret
|
|
|
|
0:
|
|
|
|
store atomic i32* %a0, i32** %a1 seq_cst, align 4
|
|
|
|
ret void
|
|
|
|
}
|