[PATCH] D73122: [mlir] Enable specifying verify on OpInterface

Jacques Pienaar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 22 04:43:54 PST 2020


jpienaar added a comment.

Updated thanks



================
Comment at: mlir/include/mlir/Analysis/InferTypeOpInterface.td:65
+  let verify = [{
+    return detail::verifyInferredResultTypes($_op);
+  }];
----------------
rriddle wrote:
> Is '$_op' documented somewhere?
Yes, in OpBase and this matches placeholder we use in other code body replacements.


================
Comment at: mlir/include/mlir/IR/OpBase.td:1417
+
+  // Specify the body of the verification function. `$_op` will be replaced with
+  // the operation being verified.
----------------
rriddle wrote:
> Why the underscore?
To match the same placeholder in line 79. I was tempted to just document that `op` will refer to the op, but given we already have those placeholders, kept it consistent.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73122/new/

https://reviews.llvm.org/D73122





More information about the llvm-commits mailing list