@@ -165,46 +165,46 @@ void LinalgDependenceGraph::addDependencesBetween(LinalgOp src, LinalgOp dst) {
165
165
LLVM_DEBUG (dbgs () << " addDependencesBetween " << *src.getOperation ()
166
166
<< " and " << *dst.getOperation () << " \n " );
167
167
if (src.hasTensorSemantics () && dst.hasTensorSemantics ()) {
168
- for (OpOperand & dstOpOperand : dst.getInputOpOperands ()) {
168
+ for (OpOperand * dstOpOperand : dst.getInputOperands ()) {
169
169
// Check if the operand is defined by the src.
170
- auto definingOp = dstOpOperand. get ().getDefiningOp <LinalgOp>();
170
+ auto definingOp = dstOpOperand-> get ().getDefiningOp <LinalgOp>();
171
171
if (definingOp && definingOp == src)
172
- addDependenceElem (DependenceType::RAW, dstOpOperand. get (),
173
- & dstOpOperand);
172
+ addDependenceElem (DependenceType::RAW, dstOpOperand-> get (),
173
+ dstOpOperand);
174
174
}
175
- for (OpOperand & dstOpOperand : dst.getOutputOpOperands ()) {
175
+ for (OpOperand * dstOpOperand : dst.getOutputOperands ()) {
176
176
// Check if the operand is defined by the src.
177
- auto definingOp = dstOpOperand. get ().getDefiningOp <LinalgOp>();
177
+ auto definingOp = dstOpOperand-> get ().getDefiningOp <LinalgOp>();
178
178
if (definingOp && definingOp == src) {
179
- if (dst.isInitTensor (& dstOpOperand)) {
180
- addDependenceElem (DependenceType::RAW, dstOpOperand. get (),
181
- & dstOpOperand);
179
+ if (dst.isInitTensor (dstOpOperand)) {
180
+ addDependenceElem (DependenceType::RAW, dstOpOperand-> get (),
181
+ dstOpOperand);
182
182
}
183
- addDependenceElem (DependenceType::WAW, dstOpOperand. get (),
184
- & dstOpOperand);
183
+ addDependenceElem (DependenceType::WAW, dstOpOperand-> get (),
184
+ dstOpOperand);
185
185
}
186
186
}
187
187
return ;
188
188
}
189
189
assert (src.hasBufferSemantics () && dst.hasBufferSemantics () &&
190
190
" unhandled dependence tracking for mixed buffer/tensor operations" );
191
- for (OpOperand *srcOpOperand : src.getOutputBuffersOpOperands ()) { // W
191
+ for (OpOperand *srcOpOperand : src.getOutputBufferOperands ()) { // W
192
192
// RAW graph
193
- for (OpOperand *dstOpOperand : dst.getInputBuffersOpOperands ()) // R
194
- if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // RAW alias
193
+ for (OpOperand *dstOpOperand : dst.getInputBufferOperands ()) // R
194
+ if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // RAW alias
195
195
addDependenceElem (DependenceType::RAW, srcOpOperand, dstOpOperand);
196
196
// WAW graph
197
- for (OpOperand *dstOpOperand : dst.getOutputBuffersOpOperands ()) // W
197
+ for (OpOperand *dstOpOperand : dst.getOutputBufferOperands ()) // W
198
198
if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // WAW alias
199
199
addDependenceElem (DependenceType::WAW, srcOpOperand, dstOpOperand);
200
200
}
201
- for (OpOperand *srcOpOperand : src.getInputBuffersOpOperands ()) { // R
201
+ for (OpOperand *srcOpOperand : src.getInputBufferOperands ()) { // R
202
202
// RAR graph
203
- for (OpOperand *dstOpOperand : dst.getInputBuffersOpOperands ()) // R
204
- if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // RAR alias
203
+ for (OpOperand *dstOpOperand : dst.getInputBufferOperands ()) // R
204
+ if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // RAR alias
205
205
addDependenceElem (DependenceType::RAR, srcOpOperand, dstOpOperand);
206
206
// WAR graph
207
- for (OpOperand *dstOpOperand : dst.getOutputBuffersOpOperands ()) // W
207
+ for (OpOperand *dstOpOperand : dst.getOutputBufferOperands ()) // W
208
208
if (aliases.alias (srcOpOperand->get (), dstOpOperand->get ())) // WAR alias
209
209
addDependenceElem (DependenceType::WAR, srcOpOperand, dstOpOperand);
210
210
}
0 commit comments