[PATCH] D78034: [mlir][spirv] Improve stride support in array types

Lei Zhang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 13 11:18:19 PDT 2020


antiagainst marked 5 inline comments as done.
antiagainst added inline comments.


================
Comment at: mlir/lib/Dialect/SPIRV/SPIRVDialect.cpp:555
+  os << "rtarray<" << type.getElementType();
+  if (unsigned stride = type.getArrayStride())
+    os << ", stride=" << type.getArrayStride();
----------------
denis13 wrote:
> denis13 wrote:
> > What do you think about
> > 
> > ```
> > if (!type.getArrayStride()) 
> > ```
> Sorry I meant
> 
> 
> ```
> if (type.getArrayStide())
> ```
Oops, good catch! I meant to reuse the `stride` value in the following line. Fixed. :)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D78034/new/

https://reviews.llvm.org/D78034





More information about the llvm-commits mailing list