[PATCH] D86065: [SVE] Make ElementCount members private

Paul Walker via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 27 04:19:57 PDT 2020


paulwalker-arm added inline comments.


================
Comment at: llvm/include/llvm/Support/TypeSize.h:108
+
+  bool isPowerOf2() const { return isPowerOf2_32(Min); }
 };
----------------
I don't believe this is safe.  For example we know SVE supported vector lengths only have to be a multiple of 128bits.  So for scalable vectors we cannot know the element count is a power of 2 unless we perform a runtime check.


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

https://reviews.llvm.org/D86065



More information about the cfe-commits mailing list