================
@@ -665,6 +665,53 @@ def CIR_LoadOp : CIR_Op<"load", [
// FIXME: add verifier.
}
+//===----------------------------------------------------------------------===//
+// MaskLoadOp
+//===----------------------------------------------------------------------===//
+
+def CIR_MaskedLoadOp : CIR_Op<"mask.load", [
+ TypesMatchWith<"type of 'result' matches pointee type of 'addr'",
+ "addr", "result", "mlir::cast<cir::PointerType>($_self).getPointee()">
+]> {
+ let summary = "Masked vector load from memory";
+ let description = [{
+ `cir.masked_load` conditionally loads elements from memory based on a mask.
+ Elements for which the mask is false are taken from `pass_thru`.
+
+ This operation is intended to correspond closely to LLVM's masked load op
+ (`llvm.intr.maskedload` / `LLVM::MaskedLoadOp`) and lower directly to it.
----------------
woruyu wrote:
Done!
https://github.com/llvm/llvm-project/pull/169464
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits