[PATCH] D77898: [SVE] Remove calls to getBitWidth from Analysis

Christopher Tetreault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 13 16:59:02 PDT 2020


ctetreau updated this revision to Diff 257158.
ctetreau added a comment.

rebase


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D77898

Files:
  llvm/include/llvm/Analysis/TargetTransformInfoImpl.h


Index: llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
===================================================================
--- llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
+++ llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
@@ -637,7 +637,8 @@
 
       // The max required size is the total vector width divided by num
       // of elements in the vector
-      unsigned MaxRequiredSize = VT->getBitWidth() / VT->getNumElements();
+      unsigned MaxRequiredSize =
+          VT->getElementType()->getPrimitiveSizeInBits().getFixedSize();
 
       unsigned MinRequiredSize = 0;
       for(unsigned i = 0, e = VT->getNumElements(); i < e; ++i) {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D77898.257158.patch
Type: text/x-patch
Size: 663 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200413/cd2bead4/attachment.bin>


More information about the llvm-commits mailing list