[PATCH] D81106: [PowerPC][NFC] Don't need to and instruction with inverse of mask.

Sean Fertile via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 15 10:23:38 PDT 2020


sfertile added a comment.

In D81106#2090619 <https://reviews.llvm.org/D81106#2090619>, @MaskRay wrote:

> Shall we mask out the bits (keep existing `(read32(loc) & ~mask)`)? If other relocations don't behave this way, let's fix it. Writing zeros to the bits is a courtesy of the assembly but should we make use of the assumption? PPC64 is a RELA target and for an RELA target the implicit addend should be relied upon. AArch64.cpp masks out the bits as well.


My concern was how the linker being nice lead to a misunderstanding of how to encode an instruction. I've left a more detailed comment in the PCREL34 review so we can keep the discussion there and I can either abandon this or commit it depending on which way the discussion goes.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D81106





More information about the llvm-commits mailing list