[PATCH] D39875: [PPC] Change i32 constant in store instruction to i64

Guozhi Wei via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 13 09:57:53 PST 2017


Carrot added a comment.

In https://reviews.llvm.org/D39875#921641, @nemanjai wrote:

> Thanks for taking care of this, I think it's quite useful and it should reduce the number of load immediate instructions and registers used. However, do we really need to expose a new API in `StoreSDNode`? Can we not just create a new truncating store using `SelectionDAG::getTruncStore()`? That would make this look a lot more like the rest of the DAG combines.


There are two SelectionDAG::getTruncStore() functions, but neither of them can accept the general (base + offset) addressing mode, so if we use getTruncStore, we still need UpdateNodeOperands to add offset if there is one.


https://reviews.llvm.org/D39875





More information about the llvm-commits mailing list