[PATCH] D45020: [mips] Accept 32-bit offsets for lb and lbu commands

Simon Dardis via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 12 12:20:40 PDT 2018


sdardis added a comment.

In https://reviews.llvm.org/D45020#1065586, @atanasyan wrote:

> In https://reviews.llvm.org/D45020#1056816, @sdardis wrote:
>
> > we should use the 'mem' operand for the lb and lbu instructions. That will allow the parser to match larger offsets than those instructions permit.
>
>
> BTW do you suggest to escape sub-classing the 'mem' operand at all? If so, we won't be able to diagnose that an operand does not fit 32 or 64 bit range.


We can diagnose the case if the operand does not fit a 32 or 64 bit range though the chain of processInstruction() -> expandMemInst() -> expand(Load|Store)Inst(). If we accept a full 64bit offset during parsing, we can determine if we should reject it after parsing while processing the instructions.


Repository:
  rL LLVM

https://reviews.llvm.org/D45020





More information about the llvm-commits mailing list