MCPcopy Create free account
hub / github.com/MegEngine/MegCC / checkInputLayout

Method checkInputLayout

compiler/lib/Dialect/Kernel/IR/KernelDialect.cpp:269–278  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

267}
268
269bool RelayoutKernel::checkInputLayout(MemRefType memref, size_t index) {
270 int64_t offset;
271 llvm::SmallVector<int64_t> stride;
272 if (failed(getStridesAndOffset(memref, stride, offset))) {
273 return false;
274 }
275
276 // could pass any strided memref to relayout
277 return true;
278}
279
280#include "compiler/Dialect/Kernel/IR/KernelInterfaces.cpp.inc"
281

Callers 1

tryMemoryForwardFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected