summaryrefslogtreecommitdiff
path: root/test/CodeGen/ARM/fence-singlethread.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/ARM/fence-singlethread.ll')
-rw-r--r--test/CodeGen/ARM/fence-singlethread.ll16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CodeGen/ARM/fence-singlethread.ll b/test/CodeGen/ARM/fence-singlethread.ll
new file mode 100644
index 000000000000..ec032ccac423
--- /dev/null
+++ b/test/CodeGen/ARM/fence-singlethread.ll
@@ -0,0 +1,16 @@
+; RUN: llc -mtriple=thumbv7-linux-gnueabihf %s -o - | FileCheck %s
+; RUN: llc -mtriple=thumbv7-apple-ios %s -o - | FileCheck %s
+; RUN: llc -mtriple=thumbv7-linux-gnueabihf %s -filetype=obj -o %t
+; RUN: llvm-objdump -d %t | FileCheck %s --check-prefix=OBJ
+
+; OBJ-NOT: dmb
+
+define void @fence_singlethread() {
+; CHECK-LABEL: fence_singlethread:
+; CHECK-NOT: dmb
+; CHECK: @ COMPILER BARRIER
+; CHECK-NOT: dmb
+
+ fence singlethread seq_cst
+ ret void
+}