Lines Matching defs:memref

49     // Zip over the resulting vector shape and memref indices.
61 memref::getMixedSize(b, loc, xferOp.getSource(), indicesIdx);
90 /// %1 = vector.transfer_read %0[...], %pad : memref<A...>, vector<...>
96 /// memref.cast %A: memref<A...> to compatibleMemRefType
100 /// memref.cast %alloc: memref<B...> to compatibleMemRefType
109 /// 2. the rank of the `xferOp.memref()` and the rank of the
142 if (memref::CastOp::areCastCompatible(aT, bT))
169 /// Casts the given memref to a compatible memref type. If the source memref has
170 /// a different address space than the target type, a `memref.memory_space_cast`
171 /// is first inserted, followed by a `memref.cast`.
172 static Value castToCompatibleMemRefType(OpBuilder &b, Value memref,
174 MemRefType sourceType = cast<MemRefType>(memref.getType());
175 Value res = memref;
180 res = b.create<memref::MemorySpaceCastOp>(memref.getLoc(), sourceType, res);
184 return b.create<memref::CastOp>(memref.getLoc(), compatibleMemRefType, res);
197 "Expected memref rank to match the alloc rank");
205 Value dimMemRef = b.create<memref::DimOp>(xferOp.getLoc(),
207 Value dimAlloc = b.create<memref::DimOp>(loc, alloc, resultIdx);
223 auto copySrc = b.create<memref::SubViewOp>(
225 auto copyDest = b.create<memref::SubViewOp>(
232 /// 2. a memref of single vector `alloc` has been allocated.
236 /// (memref.memory_space_cast %A: memref<A..., addr_space> to memref<A...>)
237 /// %view = memref.cast %A: memref<A...> to compatibleMemRefType
244 /// %5 = memref.cast %alloc: memref<B...> to compatibleMemRefType
255 Value memref = xferOp.getSource();
259 Value res = castToCompatibleMemRefType(b, memref, compatibleMemRefType);
268 // Take partial subview of memref which guarantees no dimension
274 b.create<memref::CopyOp>(loc, copyArgs.first, copyArgs.second);
286 /// 2. a memref of single vector `alloc` has been allocated.
290 /// (memref.memory_space_cast %A: memref<A..., addr_space> to memref<A...>)
291 /// memref.cast %A: memref<A...> to compatibleMemRefType
294 /// %2 = vector.transfer_read %view[...], %pad : memref<A...>, vector<...>
296 /// memref<...> to memref<vector<...>>
297 /// store %2, %3[] : memref<vector<...>>
298 /// %4 = memref.cast %alloc: memref<B...> to compatibleMemRefType
309 Value memref = xferOp.getSource();
313 Value res = castToCompatibleMemRefType(b, memref, compatibleMemRefType);
322 b.create<memref::StoreOp>(
338 /// 2. a memref of single vector `alloc` has been allocated.
342 /// memref.cast %A: memref<A...> to compatibleMemRefType
346 /// memref<...> to memref<vector<...>>
347 /// %4 = memref.cast %alloc: memref<B...> to compatibleMemRefType
357 Value memref = xferOp.getSource();
363 castToCompatibleMemRefType(b, memref, compatibleMemRefType);
383 /// 2. a memref of single vector `alloc` has been allocated.
405 b.create<memref::CopyOp>(loc, copyArgs.first, copyArgs.second);
412 /// 2. a memref of single vector `alloc` has been allocated.
418 /// %2 = load %alloc : memref<vector<...>>
419 /// vector.transfer_write %2, %view[...] : memref<A...>, vector<...>
431 Value load = b.create<memref::LoadOp>(
471 /// %1 = vector.transfer_read %0[...], %pad : memref<A...>, vector<...>
477 /// memref.cast %A: memref<A...> to compatibleMemRefType
481 /// memref.cast %alloc: memref<B...> to compatibleMemRefType
489 /// There are 2 conditional blocks. First a block to decide which memref and
495 /// vector.transfer_write %arg, %0[...], %pad : memref<A...>, vector<...>
500 /// memref.cast %A: memref<A...> to compatibleMemRefType
503 /// memref.cast %alloc: memref<B...> to compatibleMemRefType
568 alloc = b.create<memref::AllocaOp>(scope->getLoc(),