[llvm] [Xtensa] Implement lowering Mul/Div/Shift operations. (PR #99981)

Sergei Barannikov via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 5 18:07:16 PDT 2024


================
@@ -0,0 +1,566 @@
+; RUN: llc -mtriple=xtensa -verify-machineinstrs < %s \
+; RUN:   | FileCheck -check-prefix=XTENSA %s
+
+declare i8 @llvm.cttz.i8(i8, i1)
+declare i16 @llvm.cttz.i16(i16, i1)
+declare i32 @llvm.cttz.i32(i32, i1)
+declare i64 @llvm.cttz.i64(i64, i1)
+declare i8 @llvm.ctlz.i8(i8, i1)
+declare i16 @llvm.ctlz.i16(i16, i1)
+declare i32 @llvm.ctlz.i32(i32, i1)
+declare i64 @llvm.ctlz.i64(i64, i1)
+declare i8 @llvm.ctpop.i8(i8)
+declare i16 @llvm.ctpop.i16(i16)
+declare i32 @llvm.ctpop.i32(i32)
+declare i64 @llvm.ctpop.i64(i64)
+
+define i8 @test_cttz_i8(i8 %a) nounwind {
----------------
s-barannikov wrote:

There isn't much sense in testing i8 and i16 because they will be promoted to i32.

https://github.com/llvm/llvm-project/pull/99981


More information about the llvm-commits mailing list