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

Christopher Tetreault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 15 13:13:45 PDT 2020


ctetreau updated this revision to Diff 257811.
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
@@ -634,7 +634,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.257811.patch
Type: text/x-patch
Size: 664 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200415/ad9564c6/attachment.bin>


More information about the llvm-commits mailing list