[PATCH] D45748: [RISCV] Separate base from offset in lowerGlobalAddress

Sameer AbuAsal via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 16 16:20:59 PDT 2018


sabuasal added a comment.

In https://reviews.llvm.org/D45748#1100940, @asb wrote:

> I think we've all spent enough time looking at this to see that separating the base from offset in lowerGlobalAddress is a better starting point, even though there are a range of examples where it results in more instructions. I think we'll soon arrive at a solution that fixes the most common of those cases, but it's obviously not quite as straight-forward as originally hoped. If you'd like to land the change to lowerGlobalAddress quickly, I'd happily now review that as a standalone change. If you like, you could create a new review thread that includes that change as well as test cases that demonstrates where it helps, and cases where it's worse marked with TODO.


Pushed patch here: https://reviews.llvm.org/D46989
Added todo to all the corner cases we discussed in  test/CodeGen/RISCV/hoist-global-addr-base.ll


https://reviews.llvm.org/D45748





More information about the llvm-commits mailing list