[llvm] dc98adf - GlobalISel: Use MMO helper for getting the size in bits
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 7 11:26:57 PDT 2021
Author: Matt Arsenault
Date: 2021-06-07T14:26:48-04:00
New Revision: dc98adfb448bdb845605185bb173e99614a17790
URL: https://github.com/llvm/llvm-project/commit/dc98adfb448bdb845605185bb173e99614a17790
DIFF: https://github.com/llvm/llvm-project/commit/dc98adfb448bdb845605185bb173e99614a17790.diff
LOG: GlobalISel: Use MMO helper for getting the size in bits
Added:
Modified:
llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
index d7621667578a..99a60788c2a5 100644
--- a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
@@ -352,7 +352,7 @@ LegalizerInfo::getAction(const MachineInstr &MI,
SmallVector<LegalityQuery::MemDesc, 2> MemDescrs;
for (const auto &MMO : MI.memoperands())
- MemDescrs.push_back({8 * MMO->getSize() /* in bits */,
+ MemDescrs.push_back({MMO->getSizeInBits(),
8 * MMO->getAlign().value(), MMO->getOrdering()});
return getAction({MI.getOpcode(), Types, MemDescrs});
More information about the llvm-commits
mailing list