Lines Matching defs:module

61   // invalid module, so `applyOpPatternsAndFold` should come before that
80 /// replacing it with another valid operation. However, The validity of module
82 /// invalid module is still interested by the use. Thus we provide an
86 static LogicalResult findOptimal(ModuleOp module, Region &region,
90 test.isInteresting(module);
94 return module.emitWarning() << "uninterested module will not be reduced";
103 // Duplicate the module for root node and locate the region in the copy.
104 if (failed(root->initialize(module, region)))
142 if (test.isInteresting(module).first != Tester::Interestingness::True)
143 llvm::report_fatal_error("Reduced module is not interesting");
144 if (test.isInteresting(module).second != smallestNode->getSize())
146 "Reduced module doesn't have consistent size with smallestNode");
151 static LogicalResult findOptimal(ModuleOp module, Region &region,
158 // range of operations to keep to the module stay interesting.
159 if (failed(findOptimal<IteratorType>(module, region, /*patterns=*/{}, test,
164 return findOptimal<IteratorType>(module, region, patterns, test,
204 LogicalResult reduceOp(ModuleOp module, Region &region);
223 ModuleOp module = dyn_cast<ModuleOp>(topOperation);
224 if (!module) {
226 << "top-level op must be 'builtin.module'";
238 if (failed(reduceOp(module, region)))
248 LogicalResult ReductionTreePass::reduceOp(ModuleOp module, Region &region) {
253 module, region, reducerPatterns, test);
255 return module.emitError() << "unsupported traversal mode detected";