1; RUN: opt -codegenprepare -S < %s | FileCheck %s 2 3@tmp = global i8 0 4 5; CHECK-LABEL: define void @foo() { 6define void @foo() { 7enter: 8 ; CHECK-NOT: !invariant.group 9 ; CHECK-NOT: @llvm.invariant.group.barrier( 10 ; CHECK: %val = load i8, i8* @tmp 11 %val = load i8, i8* @tmp, !invariant.group !0 12 %ptr = call i8* @llvm.invariant.group.barrier(i8* @tmp) 13 14 ; CHECK: store i8 42, i8* @tmp 15 store i8 42, i8* %ptr, !invariant.group !0 16 17 ret void 18} 19; CHECK-LABEL: } 20 21declare i8* @llvm.invariant.group.barrier(i8*) 22 23!0 = !{!"something"}