[llvm-dev] Updating the Chain

Tim Northover via llvm-dev llvm-dev at lists.llvm.org
Tue Sep 25 08:47:03 PDT 2018


Hi Dominique,

On Tue, 25 Sep 2018 at 16:06, Dominique Torette via llvm-dev
<llvm-dev at lists.llvm.org> wrote:
> The SelectNodeTo() API build the composed result value, but does not update all the chain links to the new position. Is there an API to update all the references in the chain to this new position?

I think you want SelectionDAG::ReplaceAllUsesOfValueWith, if you're
changing the node outputs. ReplaceAllUsesWith is similar but wholesale
maps all output values of the SDNode between the two (confusingly,
even the version that takes an SDValue does that).

Cheers.

Tim.


More information about the llvm-dev mailing list