Home
last modified time | relevance | path

Searched refs:bbArg (Results 1 – 22 of 22) sorted by relevance

/llvm-project-15.0.7/mlir/lib/Dialect/Bufferization/Transforms/
H A DOneShotModuleBufferize.cpp156 for (BlockArgument bbArg : funcOp.getArguments()) in aliasingFuncOpBBArgsAnalysis() local
157 if (bbArg.getType().isa<RankedTensorType>()) { in aliasingFuncOpBBArgsAnalysis()
159 int64_t bbArgIdx = bbArg.getArgNumber(); in aliasingFuncOpBBArgsAnalysis()
208 for (BlockArgument bbArg : funcOp.getArguments()) { in funcOpBbArgReadWriteAnalysis() local
209 if (!bbArg.getType().isa<TensorType>()) in funcOpBbArgReadWriteAnalysis()
211 bool isRead = state.isValueRead(bbArg); in funcOpBbArgReadWriteAnalysis()
212 bool isWritten = state.isValueWritten(bbArg); in funcOpBbArgReadWriteAnalysis()
228 funcOp.removeArgAttr(bbArg.getArgNumber(), in removeBufferizationAttributes()
230 funcOp.removeArgAttr(bbArg.getArgNumber(), in removeBufferizationAttributes()
434 for (BlockArgument bbArg : op.getArguments()) in bufferizeModuleOp() local
[all …]
H A DOneShotAnalysis.cpp108 for (auto bbArg : b.getArguments()) in BufferizationAliasInfo() local
109 if (bbArg.getType().isa<TensorType>()) in BufferizationAliasInfo()
110 createAliasInfoEntry(bbArg); in BufferizationAliasInfo()
243 if (auto bbArg = v.dyn_cast<BlockArgument>()) { in gatherYieldedTensors() local
245 yieldedTensors.insert(bbArg); in gatherYieldedTensors()
315 if (auto bbArg = value.dyn_cast<BlockArgument>()) in isWritable() local
318 return bufferizableOp.isWritable(bbArg, *this); in isWritable()
407 auto bbArg = lastWrite.cast<BlockArgument>(); in annotateConflict() local
552 auto bbArg = lastWrite.cast<BlockArgument>(); in hasReadAfterWriteInterference() local
553 Block *block = bbArg.getOwner(); in hasReadAfterWriteInterference()
[all …]
H A DFuncBufferizableOpInterfaceImpl.cpp431 for (BlockArgument &bbArg : frontBlock.getArguments()) { in bufferize()
432 auto tensorType = bbArg.getType().dyn_cast<TensorType>(); in bufferize()
439 for (OpOperand &use : bbArg.getUses()) in bufferize()
444 getBufferizedFunctionArgType(funcOp, bbArg.getArgNumber(), options); in bufferize()
445 bbArg.setType(memrefType); in bufferize()
453 rewriter.create<bufferization::ToTensorOp>(funcOp.getLoc(), bbArg); in bufferize()
499 BlockArgument bbArg = value.dyn_cast<BlockArgument>(); in isWritable() local
500 assert(bbArg && "expected BlockArgument"); in isWritable()
505 bbArg.getArgNumber(), BufferizationDialect::kWritableAttrName)) in isWritable()
H A DAllocTensorElimination.cpp30 if (auto bbArg = val.dyn_cast<BlockArgument>()) { in neededValuesDominateInsertionPoint() local
31 Block *owner = bbArg.getOwner(); in neededValuesDominateInsertionPoint()
72 if (auto bbArg = val.dyn_cast<BlockArgument>()) { in findValidInsertionPoint() local
74 &bbArg.getOwner()->getOperations().front()); in findValidInsertionPoint()
H A DDropEquivalentBufferResults.cpp80 for (BlockArgument bbArg : funcOp.getArguments()) { in dropEquivalentBufferResults() local
85 if (val == bbArg) { in dropEquivalentBufferResults()
86 resultToArgs[it.index()] = bbArg.getArgNumber(); in dropEquivalentBufferResults()
/llvm-project-15.0.7/mlir/lib/Dialect/Linalg/Transforms/
H A DFusionOnTensors.cpp226 if (bbArg.getOwner()->getParentOp() != tileLoop) in getTiedBBArgs()
228 bbArgs.push_back(bbArg); in getTiedBBArgs()
230 bbArg = iterArg->get().dyn_cast<BlockArgument>(); in getTiedBBArgs()
239 SmallVector<BlockArgument> bbArgs = getTiedBBArgs(bbArg); in getTiedIterArg()
245 bool TileLoopNest::hasOtherUses(BlockArgument bbArg, in hasOtherUses() argument
250 for (Operation *op : bbArg.getUsers()) { in hasOtherUses()
270 return !all_of(bbArgs, [&](BlockArgument bbArg) { in hasOtherUses() argument
271 return bbArg.hasOneUse() || bbArg == bbArgs.back(); in hasOtherUses()
356 if (bbArg.getUses().empty()) in fuseProducer()
363 iterArg = getTiedIterArg(bbArg); in fuseProducer()
[all …]
H A DElementwiseOpFusion.cpp178 for (BlockArgument bbArg : consumerBlock.getArguments().take_front( in generateFusedElementwiseOpRegion() local
180 mapper.map(bbArg, fusedBlock->addArgument(bbArg.getType(), bbArg.getLoc())); in generateFusedElementwiseOpRegion()
186 for (BlockArgument bbArg : in generateFusedElementwiseOpRegion() local
188 mapper.map(bbArg, fusedBlock->addArgument(bbArg.getType(), bbArg.getLoc())); in generateFusedElementwiseOpRegion()
194 BlockArgument bbArg = producerBlock.getArguments() in generateFusedElementwiseOpRegion() local
198 mapper.map(bbArg, fusedBlock->addArgument(bbArg.getType(), bbArg.getLoc())); in generateFusedElementwiseOpRegion()
201 for (BlockArgument bbArg : in generateFusedElementwiseOpRegion() local
205 mapper.map(bbArg, fusedBlock->addArgument(bbArg.getType(), bbArg.getLoc())); in generateFusedElementwiseOpRegion()
207 for (BlockArgument bbArg : in generateFusedElementwiseOpRegion() local
209 mapper.map(bbArg, fusedBlock->addArgument(bbArg.getType(), bbArg.getLoc())); in generateFusedElementwiseOpRegion()
H A DHoisting.cpp243 auto bbArg = insertSliceOp.getDest().dyn_cast<BlockArgument>(); in getLoopInvariantTransferWriteOpDefining() local
244 if (!bbArg || bbArg.getOwner()->getParentOp() != forOp || in getLoopInvariantTransferWriteOpDefining()
245 bbArg.getArgNumber() != /*num iv=*/1 + yieldOperand.getOperandNumber()) in getLoopInvariantTransferWriteOpDefining()
/llvm-project-15.0.7/mlir/lib/Dialect/Bufferization/IR/
H A DBufferizableOpInterface.cpp310 if (auto bbArg = value.dyn_cast<BlockArgument>()) { in setInsertionPointAfter() local
311 b.setInsertionPointToStart(bbArg.getOwner()); in setInsertionPointAfter()
582 if (auto bbArg = value.dyn_cast<BlockArgument>()) in getBufferType() local
584 options.dynCastBufferizableOp(bbArg.getOwner()->getParentOp())) in getBufferType()
585 return bufferizableOp.getBufferType(bbArg, options); in getBufferType()
691 auto bbArg = value.dyn_cast<BlockArgument>(); in isFunctionArgument() local
692 if (!bbArg) in isFunctionArgument()
694 return isa<func::FuncOp>(bbArg.getOwner()->getParentOp()); in isFunctionArgument()
/llvm-project-15.0.7/mlir/include/mlir/Dialect/Linalg/Utils/
H A DUtils.h423 SmallVector<BlockArgument> getTiedBBArgs(BlockArgument bbArg);
427 OpOperand *getTiedIterArg(BlockArgument bbArg);
432 bool hasOtherUses(BlockArgument bbArg, tensor::ExtractSliceOp sliceOp);
/llvm-project-15.0.7/mlir/lib/Dialect/SCF/Transforms/
H A DBufferizableOpInterfaceImpl.cpp405 auto bbArg = forOp.getRegionIterArgForOpOperand(forOperand); in bufferRelation() local
409 bbArg, yieldOp->getOperand(opResult.getResultNumber())); in bufferRelation()
475 getBufferType(Operation *op, BlockArgument bbArg, in getBufferType()
479 forOp.getOpOperandForRegionIterArg(bbArg).get(), options); in getBufferType()
738 llvm::map_range(whileOp.getAfterArguments(), [&](BlockArgument bbArg) { in bufferize() argument
740 return bufferization::getBufferType(bbArg, options)->cast<Type>(); in bufferize()
/llvm-project-15.0.7/mlir/include/mlir/Dialect/Bufferization/IR/
H A DBufferizableOpInterface.td348 /*args=*/(ins "BlockArgument":$bbArg,
352 assert(bbArg.getOwner()->getParentOp() == $_op &&
353 "bbArg must belong to this op");
354 assert(bbArg.getType().isa<TensorType>() &&
356 return bufferization::getMemRefType(bbArg, options);
/llvm-project-15.0.7/mlir/test/Dialect/Bufferization/Transforms/
H A Done-shot-module-bufferize-invalid.mlir102 // expected-error @+1 {{Yield operand #0 is not equivalent to the corresponding iter bbArg}}
120 // expected-error @+1 {{Condition arg #0 is not equivalent to the corresponding iter bbArg}}
150 // expected-error @+1 {{Yield operand #0 is not equivalent to the corresponding iter bbArg}}
173 // expected-error @+1 {{Yield operand #0 is not equivalent to the corresponding iter bbArg}}
H A Done-shot-module-bufferize-out-params.mlir48 // entirely because the buffer is equivalent to a bbArg.
H A Done-shot-module-bufferize.mlir526 // Note: `callee` does not write to its bbArg directly, but `external_func`
577 // inner_func_2 modifies the bbArg, but the loop yields the original value. A
/llvm-project-15.0.7/mlir/include/mlir/Dialect/SCF/IR/
H A DSCFOps.td279 OpOperand &getOpOperandForRegionIterArg(BlockArgument bbArg) {
280 assert(bbArg.getArgNumber() >= getNumInductionVars() &&
281 "expected a bbArg that is not an induction variable");
282 assert(bbArg.getOwner()->getParentOp() == getOperation() &&
283 "bbArg does not belong to the scf::ForOp body");
285 getNumControlOperands() + bbArg.getArgNumber() - getNumInductionVars());
/llvm-project-15.0.7/mlir/lib/Dialect/SCF/IR/
H A DSCF.cpp974 for (BlockArgument bbArg : forOp.getRegionIterArgs()) { in matchAndRewrite() local
975 unsigned idx = bbArg.getArgNumber() - /*numIv=*/1; in matchAndRewrite()
980 bool isTensor = bbArg.getType().isa<TensorType>(); in matchAndRewrite()
984 if (bbArg.hasOneUse()) in matchAndRewrite()
986 dyn_cast<bufferization::ToMemrefOp>(*bbArg.getUsers().begin()); in matchAndRewrite()
987 if (!isTensor || !tensorLoadOp || (!bbArg.use_empty() && !tensorToMemref)) in matchAndRewrite()
1012 Value forOpResult = forOp.getResult(bbArg.getArgNumber() - /*iv=*/1); in matchAndRewrite()
1018 yieldOp.setOperand(idx, bbArg); in matchAndRewrite()
/llvm-project-15.0.7/mlir/lib/Dialect/Vector/Transforms/
H A DVectorDistribute.cpp48 Value bbArg = warpOpBody->getArgument(it.index()); in rewriteWarpOpToScfFor() local
52 options.warpAllocationFn(loc, rewriter, warpOp, bbArg.getType()); in rewriteWarpOpToScfFor()
65 auto bbArgType = bbArg.getType().cast<VectorType>(); in rewriteWarpOpToScfFor()
/llvm-project-15.0.7/mlir/include/mlir/Dialect/Bufferization/Transforms/
H A DPasses.td158 let summary = "Remove MemRef return values that are equivalent to a bbArg";
161 to a function bbArg. In that case, the return value is redundant and the
164 Note: If a bbArg buffer is not returned directly but casted to beforehand,
/llvm-project-15.0.7/mlir/test/Dialect/SCF/
H A Done-shot-bufferize-analysis.mlir53 // which makes bbArg inplaceable.
54 // 2. Or it is already inplaceable and so is bbArg.
H A Dcanonicalize.mlir773 // This does not hoist (fails the bbArg has at most a single check).
/llvm-project-15.0.7/mlir/docs/
H A DBufferization.md430 from a function is not supported, unless it is equivalent to a function bbArg.