[PATCH] D60799: Add a getSizeInBits() accessor to MachineMemOperand. NFC.

Amara Emerson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 17 14:46:16 PDT 2019


aemerson marked an inline comment as done.
aemerson added inline comments.


================
Comment at: llvm/lib/CodeGen/MachineVerifier.cpp:1028
       } else if (MI->getOpcode() == TargetOpcode::G_LOAD) {
-        if (MMO.getSize() > (ValTy.getSizeInBits() + 7) / 8)
+        if (MMO.getSizeInBits() > (ValTy.getSizeInBits() + 7))
           report("load memory size cannot exceed result size", MI);
----------------
arsenm wrote:
> The +7 / 8 trick should probably be moved into a ValTy.getSizeInBytes()
I'll do this when I commit.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D60799





More information about the llvm-commits mailing list