[Assignment Tracking][SROA] Handle DIArgList in migrateDebugInfo
authorOCHyams <orlando.hyams@sony.com>
Fri, 31 Mar 2023 11:06:35 +0000 (12:06 +0100)
committerOCHyams <orlando.hyams@sony.com>
Fri, 31 Mar 2023 11:38:47 +0000 (12:38 +0100)
commit01c02cded15a65e7511988272e70fec76950e934
treedf98c863f8e6c187b2e1f3a9bff1626adbb9985c
parent32c7b03430573feea56d8e8db7013c281975b83d
[Assignment Tracking][SROA] Handle DIArgList in migrateDebugInfo

If the to-be-split dbg.assign has a `DIArgList` and a new `Value` has been
requested then use a kill-location for the new dbg.assign. We can't simply
replace the value component (a `DIArgList`) with the new `Value` as that would
leave the `DIExpression` in an invalid state (`DW_OP_LLVM_arg` operands with no
arglist).

Reviewed By: jmorse

Differential Revision: https://reviews.llvm.org/D147312
llvm/lib/Transforms/Scalar/SROA.cpp
llvm/test/DebugInfo/Generic/assignment-tracking/sroa/arglist.ll [new file with mode: 0644]