mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-13 14:46:53 +00:00
f3abce4a8e
For more info for what reason it was invented, goto: http://lists.llvm.org/pipermail/cfe-dev/2015-July/044227.html invariant.group.barrier: http://reviews.llvm.org/D12310 docs: http://reviews.llvm.org/D11399 CodeGenPrepare: http://reviews.llvm.org/D12875 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@247711 91177308-0d34-0410-b5e6-96231b3b80d8
23 lines
538 B
LLVM
23 lines
538 B
LLVM
; RUN: opt -codegenprepare -S < %s | FileCheck %s
|
|
|
|
@tmp = global i8 0
|
|
|
|
; CHECK-LABEL: define void @foo() {
|
|
define void @foo() {
|
|
enter:
|
|
; CHECK-NOT: !invariant.group
|
|
; CHECK-NOT: @llvm.invariant.group.barrier(
|
|
; CHECK: %val = load i8, i8* @tmp
|
|
%val = load i8, i8* @tmp, !invariant.group !0
|
|
%ptr = call i8* @llvm.invariant.group.barrier(i8* @tmp)
|
|
|
|
; CHECK: store i8 42, i8* @tmp
|
|
store i8 42, i8* %ptr, !invariant.group !0
|
|
|
|
ret void
|
|
}
|
|
; CHECK-LABEL: }
|
|
|
|
declare i8* @llvm.invariant.group.barrier(i8*)
|
|
|
|
!0 = !{!"something"} |