[PATCH] D46423: [WIP, RISCV] Support .option relax and .option norelax

Alex Bradbury via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 4 06:16:44 PDT 2018


asb added a comment.

In https://reviews.llvm.org/D46423#1255106, @lewis-revill wrote:

> Well apologies for the noise and the late update, but it looks like we can't have an early `.option norelax` overriding the behaviour specified with `mattr=+relax`. This is because the lazy `ForceRelocs` variable was only set when parsing assembly, so with a standard IR pipeline this is never set so relocations are never emitted. This update reverses this behaviour but keeps the lazy behaviour when parsing assembly when `-mattr=-relax` is used.


I suspected that might be an issue. Can you double check the test coverage? I would have hoped to have seen some failures in test/CodeGen with the previous version of this patch. It looks like fixups-diff.ll is the only codegen test that would be affected, but I think it passed with the previous version of the patch when I tried it.


Repository:
  rL LLVM

https://reviews.llvm.org/D46423





More information about the llvm-commits mailing list