brintos

brintos / llvm-project-archived public Read only

0
0
Text · 759 B · 96abdfc Raw
28 lines · plain
1; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv64-unknown-unknown %s -o - | FileCheck %s2 3; CHECK: %[[#extinst_id:]] = OpExtInstImport "OpenCL.std"4 5; CHECK: OpFunction6; CHECK: %[[#]] = OpExtInst %[[#]] %[[#extinst_id]] ctz7; CHECK: OpFunctionEnd8 9define spir_func i32 @TestCtz(i32 %x) local_unnamed_addr {10entry:11  %0 = tail call i32 @llvm.cttz.i32(i32 %x, i1 true)12  ret i32 %013}14 15; CHECK: OpFunction16; CHECK: %[[#]] = OpExtInst %[[#]] %[[#extinst_id]] ctz17; CHECK: OpFunctionEnd18 19define spir_func <4 x i32> @TestCtzVec(<4 x i32> %x) local_unnamed_addr {20entry:21  %0 = tail call <4 x i32> @llvm.cttz.v4i32(<4 x i32> %x, i1 true)22  ret <4 x i32> %023}24 25declare i32 @llvm.cttz.i32(i32, i1 immarg)26 27declare <4 x i32> @llvm.cttz.v4i32(<4 x i32>, i1 immarg)28