[llvm] [NVPTX] Attempt to load params using symbol addition node directly (PR #119935)

Kevin McAfee via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 16 14:51:17 PST 2024


kalxr wrote:

> > Inserting a MoveParam is undesirable in the general case, so we would only want to do it when DAG combines are disabled.
> 
> Do you have a case where inserting the `mov` introduced a SASS diff during `-O3` compilation?

This isn't how I would make the change if I was doing it for real, but if you add something like `SDValue MP = DAG.getNode(NVPTXISD::MoveParam, dl, PtrVT, Arg);` at https://github.com/llvm/llvm-project/blob/8c163237573df097a99b65a83280757d1b39062c/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp#L3120 and then replace the use of `Arg` in the following `getNode`, PTX generated from the test case included in this PR will have the mov and the SASS will be different.

https://github.com/llvm/llvm-project/pull/119935


More information about the llvm-commits mailing list