[CSInfo][MIPS] Update CSInfo in delay slot filler
authorDjordje Todorovic <djordje.todorovic@syrmia.com>
Mon, 18 Jan 2021 14:26:40 +0000 (15:26 +0100)
committerDjordje Todorovic <djolertrk@gmail.com>
Mon, 18 Jan 2021 14:29:59 +0000 (15:29 +0100)
commit2040c1110b661caae7999abc0158a7f57a6400fb
tree3a15915121c1e6498a51e6e031074d099003a2e4
parentead71a23edde5f8a1acfdd75bd01f1fa6e0c4014
[CSInfo][MIPS] Update CSInfo in delay slot filler

In MipsDelaySlotFiller, when replacing old call-branch with
the compact branch instruction, an assertion is caused by erasing
the old call with unhandled CSInfo.
The problem was reported in PR48695.
This patch fixes it, by moving call site info from the old call
instruction to its replace.

Patch by Nikola Tesic

Differential revision: https://reviews.llvm.org/D94685
llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp
llvm/test/DebugInfo/MIR/Mips/call-site-info-update-delay-slot-filler.mir [new file with mode: 0644]