================
@@ -208,6 +209,19 @@ static bool omitRegionTerm(mlir::Region &r) {
return singleNonEmptyBlock && yieldsNothing();
}
+// Verifies that the given operand is produced by an operation of type
+// ExpectedProducerOp.
+template <typename ExpectedProducerOp>
+static LogicalResult verifyProducedBy(Operation *op, Value operand,
+ StringRef operandName) {
+ Operation *producer = operand.getDefiningOp();
+ if (!producer || !isa<ExpectedProducerOp>(producer))
----------------
erichkeane wrote:
Does this prohibit moving the memory to a 'global' at any point? IS that
something we do/have interest in doing at any point?
https://github.com/llvm/llvm-project/pull/199599
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits