Home
last modified time | relevance | path

Searched refs:ForOp (Results 1 – 25 of 41) sorted by relevance

12

/external/llvm-project/mlir/include/mlir/Transforms/
DLoopUtils.h33 class ForOp; variable
45 LogicalResult loopUnrollByFactor(scf::ForOp forOp, uint64_t unrollFactor);
61 void getPerfectlyNestedLoops(SmallVectorImpl<scf::ForOp> &nestedLoops,
62 scf::ForOp root);
77 LogicalResult promoteIfSingleIteration(scf::ForOp forOp);
145 using Loops = SmallVector<scf::ForOp, 8>;
150 SmallVector<Loops, 8> tile(ArrayRef<scf::ForOp> forOps, ArrayRef<Value> sizes,
151 ArrayRef<scf::ForOp> targets);
159 Loops tile(ArrayRef<scf::ForOp> forOps, ArrayRef<Value> sizes,
160 scf::ForOp target);
[all …]
/external/llvm-project/mlir/lib/Dialect/SCF/Transforms/
DStructuralTypeConversions.cpp20 class ConvertForOpTypes : public OpConversionPattern<ForOp> {
24 matchAndRewrite(ForOp op, ArrayRef<Value> operands, in matchAndRewrite()
52 ForOp newOp = cast<ForOp>(rewriter.cloneWithoutRegions(*op.getOperation())); in matchAndRewrite()
141 target.addDynamicallyLegalOp<ForOp, IfOp>([&](Operation *op) { in populateSCFStructuralTypeConversionsAndLegality()
147 if (!isa<ForOp, IfOp>(op->getParentOp())) in populateSCFStructuralTypeConversionsAndLegality()
DUtils.cpp25 scf::ForOp mlir::cloneWithNewYields(OpBuilder &b, scf::ForOp loop, in cloneWithNewYields()
37 scf::ForOp newLoop = in cloneWithNewYields()
38 b.create<scf::ForOp>(loop.getLoc(), loop.lowerBound(), loop.upperBound(), in cloneWithNewYields()
DLoopSpecialization.cpp23 using scf::ForOp;
67 static void specializeForLoopForUnrolling(ForOp op) { in specializeForLoopForUnrolling()
104 getFunction().walk([](ForOp op) { specializeForLoopForUnrolling(op); }); in runOnFunction()
/external/llvm-project/mlir/include/mlir/Dialect/SCF/
DUtils.h25 class ForOp; variable
48 scf::ForOp cloneWithNewYields(OpBuilder &b, scf::ForOp loop,
DSCF.h46 ForOp getForInductionVarOwner(Value val);
54 using LoopVector = std::vector<scf::ForOp>;
/external/llvm-project/mlir/test/lib/Transforms/
DTestLoopUnrolling.cpp27 if (isa<scf::ForOp>(currOp)) in getNestingDepth()
46 SmallVector<scf::ForOp, 4> loops; in runOnFunction()
47 func.walk([&](scf::ForOp forOp) { in runOnFunction()
DTestLoopParametricTiling.cpp36 func.walk([this](scf::ForOp op) { in runOnFunction()
38 if (op->getParentRegion()->getParentOfType<scf::ForOp>()) in runOnFunction()
DTestLoopMapping.cpp44 func.walk([&processorIds, &numProcessors](scf::ForOp op) { in runOnFunction()
46 if (op->getParentRegion()->getParentOfType<scf::ForOp>()) in runOnFunction()
DTestSCFUtils.cpp31 SmallVector<scf::ForOp, 4> toErase; in runOnFunction()
38 auto loop = fakeRead->getParentOfType<scf::ForOp>(); in runOnFunction()
/external/llvm-project/mlir/lib/Transforms/
DLoopCoalescing.cpp26 func.walk([](scf::ForOp op) { in runOnFunction()
28 if (op->getParentOfType<scf::ForOp>()) in runOnFunction()
31 SmallVector<scf::ForOp, 4> loops; in runOnFunction()
/external/llvm-project/mlir/lib/Dialect/SCF/
DSCF.cpp74 void ForOp::build(OpBuilder &builder, OperationState &result, Value lb, in build()
92 ForOp::ensureTerminator(*bodyRegion, builder, result.location); in build()
101 static LogicalResult verify(ForOp op) { in verify()
164 static void print(OpAsmPrinter &p, ForOp op) { in print()
225 ForOp::ensureTerminator(*body, builder, result.location); in parseForOp()
234 Region &ForOp::getLoopBody() { return region(); } in getLoopBody()
236 bool ForOp::isDefinedOutsideOfLoop(Value value) { in isDefinedOutsideOfLoop()
240 LogicalResult ForOp::moveOutOfLoop(ArrayRef<Operation *> ops) { in moveOutOfLoop()
246 ForOp mlir::scf::getForInductionVarOwner(Value val) { in getForInductionVarOwner()
249 return ForOp(); in getForInductionVarOwner()
[all …]
/external/llvm-project/mlir/lib/Conversion/SCFToStandard/
DSCFToStandard.cpp97 struct ForLowering : public OpRewritePattern<ForOp> {
98 using OpRewritePattern<ForOp>::OpRewritePattern;
100 LogicalResult matchAndRewrite(ForOp forOp,
282 LogicalResult ForLowering::matchAndRewrite(ForOp forOp, in matchAndRewrite()
423 ForOp forOp = rewriter.create<ForOp>(loc, lower, upper, step, iterArgs); in matchAndRewrite()
584 target.addIllegalOp<scf::ForOp, scf::IfOp, scf::ParallelOp, scf::WhileOp>(); in runOnOperation()
/external/tensorflow/tensorflow/compiler/mlir/tfr/passes/
Dcanonicalize.cc49 struct UnrollSCFForOp : public OpRewritePattern<scf::ForOp> {
50 using OpRewritePattern<scf::ForOp>::OpRewritePattern;
51 LogicalResult matchAndRewrite(scf::ForOp for_op, in matchAndRewrite()
/external/llvm-project/mlir/lib/Dialect/Async/Transforms/
DAsyncParallelFor.cpp190 b.create<scf::ForOp>( in matchAndRewrite()
231 b.create<scf::ForOp>(loc, c0, numBlocks[loopIdx + 1], c1, ValueRange(), in matchAndRewrite()
242 executeBuilder.create<scf::ForOp>(executeLoc, blockLowerBounds[0], in matchAndRewrite()
258 rewriter.create<scf::ForOp>(loc, c0, numBlocks[0], c1, ValueRange(), in matchAndRewrite()
/external/llvm-project/mlir/lib/Conversion/SCFToSPIRV/
DSCFToSPIRV.cpp56 class ForOpConversion final : public SCFToSPIRVPattern<scf::ForOp> {
58 using SCFToSPIRVPattern<scf::ForOp>::SCFToSPIRVPattern;
61 matchAndRewrite(scf::ForOp forOp, ArrayRef<Value> operands,
123 ForOpConversion::matchAndRewrite(scf::ForOp forOp, ArrayRef<Value> operands, in matchAndRewrite()
/external/llvm-project/mlir/lib/Transforms/Utils/
DLoopUtils.cpp195 LogicalResult mlir::promoteIfSingleIteration(scf::ForOp forOp) { in promoteIfSingleIteration()
238 else if (auto forOp = dyn_cast<scf::ForOp>(op)) in promoteSingleIterationLoops()
1011 void mlir::getPerfectlyNestedLoops(SmallVectorImpl<scf::ForOp> &nestedLoops, in getPerfectlyNestedLoops()
1012 scf::ForOp root) { in getPerfectlyNestedLoops()
1163 LogicalResult mlir::loopUnrollByFactor(scf::ForOp forOp, in loopUnrollByFactor()
1238 auto epilogueForOp = cast<scf::ForOp>(epilogueBuilder.clone(*forOp)); in loopUnrollByFactor()
1689 static Loops stripmineSink(scf::ForOp forOp, Value factor, in stripmineSink()
1690 ArrayRef<scf::ForOp> targets) { in stripmineSink()
1712 auto newForOp = b.create<scf::ForOp>(t.getLoc(), iv, ub, originalStep); in stripmineSink()
1758 SmallVector<Loops, 8> mlir::tile(ArrayRef<scf::ForOp> forOps, in tile()
[all …]
/external/llvm-project/mlir/lib/Dialect/Linalg/Transforms/
DHoisting.cpp46 auto loop = dyn_cast<scf::ForOp>(op->getParentOp()); in hoistViewAllocOps()
92 auto loop = dyn_cast<scf::ForOp>(transferRead->getParentOp()); in hoistRedundantVectorTransfers()
/external/llvm-project/mlir/include/mlir/Conversion/SCFToGPU/
DSCFToGPU.h22 class ForOp; variable
/external/tensorflow/tensorflow/compiler/mlir/tools/kernel_gen/transforms/
Dparallel_loops_to_sequential.cc37 target.addLegalOp<mlir::scf::ForOp, mlir::scf::IfOp>(); in runOnFunction()
/external/llvm-project/mlir/lib/Analysis/
DSliceAnalysis.cpp48 } else if (auto forOp = dyn_cast<scf::ForOp>(op)) { in getForwardSliceImpl()
89 isa<AffineForOp, scf::ForOp, linalg::LinalgOp>(op)) && in getBackwardSliceImpl()
/external/tensorflow/tensorflow/core/kernels/
Dfunctional_ops.cc728 class ForOp : public AsyncOpKernel { class
730 explicit ForOp(OpKernelConstruction* ctx) : AsyncOpKernel(ctx) { in ForOp() function in tensorflow::__anonf02e412f0111::ForOp
738 ~ForOp() override {} in ~ForOp()
749 State(ForOp* kernel, OpKernelContext* ctx, DoneCallback done) in State()
773 ForOp* const kernel_;
850 REGISTER_KERNEL_BUILDER(Name("For").Device(DEVICE_CPU), ForOp);
856 ForOp);
/external/llvm-project/mlir/lib/Dialect/GPU/Transforms/
DMemoryPromotion.cpp94 auto loop = cast<scf::ForOp>(v.getParentRegion()->getParentOp()); in insertCopyLoops()
/external/llvm-project/mlir/lib/Conversion/ShapeToStandard/
DConvertShapeConstraints.cpp64 rewriter.create<scf::ForOp>( in matchAndRewrite()
/external/llvm-project/mlir/lib/Dialect/Linalg/Utils/
DUtils.cpp82 template struct mlir::linalg::GenerateLoopNest<scf::ForOp>;
126 void GenerateLoopNest<scf::ForOp>::doit( in doit()

12