================
@@ -409,6 +409,15 @@ __device__ void test_lerp(unsigned int* out, unsigned int 
src0, unsigned int src
   *out = __builtin_amdgcn_lerp(src0, src1, src2);
 }
 
+// CIR-LABEL: @_Z13test_alignbitPjjjj
+// CIR: cir.fshr {{.*}} : !u32i
+// LLVM: define{{.*}} void @_Z13test_alignbitPjjjj
+// LLVM: call{{.*}} i32 @llvm.fshr.i32(i32 %{{.+}}, i32 %{{.+}}, i32 %{{.+}})
----------------
skc7 wrote:

Nit: could the test check the operand order? Capturing the three loaded args 
and matching them in `cir.fshr` and in the `llvm.fshr` call would catch a 
swapped `src0/src1`.
The classic test in `CodeGenOpenCL/builtins-amdgcn.cl` does this with `%src0, 
%src1, %src2`.

https://github.com/llvm/llvm-project/pull/242166
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to