Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / CodeGen / SPIRV / capability-Int64Atomics.ll
blob65047f8c6e48f4c5d1c6fdba57f8ded201d4c6f8
1 ;; OpenCL C source:
2 ;; #pragma OPENCL EXTENSION cl_khr_int64_base_atomics : enable
3 ;; #pragma OPENCL EXTENSION cl_khr_int64_extended_atomics : enable
4 ;;
5 ;; void foo (volatile atomic_long *object, long desired) {
6 ;;   atomic_fetch_xor(object, desired);
7 ;; }
9 ; RUN: llc -O0 -mtriple=spirv64-unknown-unknown %s -o - | FileCheck %s
11 ; CHECK: OpCapability Int64Atomics
13 define spir_func void @foo(i64 addrspace(4)* %object, i64 %desired) {
14 entry:
15   %call = tail call spir_func i64 @_Z16atomic_fetch_xorPVU3AS4U7_Atomicll(i64 addrspace(4)* %object, i64 %desired)
16   ret void
19 declare spir_func i64 @_Z16atomic_fetch_xorPVU3AS4U7_Atomicll(i64 addrspace(4)*, i64)