================
@@ -511,6 +512,16 @@ mlir::LogicalResult
CIRToLLVMLLVMIntrinsicCallOpLowering::matchAndRewrite(
return mlir::success();
}
+/// BoolAttr visitor.
+mlir::Value CIRAttrToValue::visitCirAttr(cir::BoolAttr boolAttr) {
+ mlir::Location loc = parentOp->getLoc();
+ mlir::DataLayout layout(parentOp->getParentOfType<mlir::ModuleOp>());
+ mlir::Value boolVal = mlir::LLVM::ConstantOp::create(
+ rewriter, loc, converter->convertType(boolAttr.getType()),
+ boolAttr.getValue());
+ return emitToMemory(rewriter, layout, boolAttr.getType(), boolVal);
----------------
erichkeane wrote:
Curious why this needs an `emitToMemory` but `IntAttr` just below doesn't?
https://github.com/llvm/llvm-project/pull/187590
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits