[clang] [CIR] Add rotate operation (PR #148426)
Henrich Lauko via cfe-commits
cfe-commits at lists.llvm.org
Mon Jul 14 04:53:59 PDT 2025
================
@@ -872,6 +872,21 @@ mlir::LogicalResult CIRToLLVMReturnOpLowering::matchAndRewrite(
return mlir::LogicalResult::success();
}
+mlir::LogicalResult CIRToLLVMRotateOpLowering::matchAndRewrite(
+ cir::RotateOp op, OpAdaptor adaptor,
+ mlir::ConversionPatternRewriter &rewriter) const {
+ // Note that LLVM intrinsic calls to @llvm.fsh{r,l}.i* have the same type as
+ // the operand.
+ auto input = adaptor.getInput();
+ if (op.getIsRotateLeft())
----------------
xlauko wrote:
```suggestion
if (op.isRotateLeft())
```
https://github.com/llvm/llvm-project/pull/148426
More information about the cfe-commits
mailing list