[LoongArch] Transfer MI flags when expand PseudoCALL
commit7da2d69da6a8aa5f1d55284910efe27bf64106b2
authorwanglei <wanglei@loongson.cn>
Thu, 17 Nov 2022 01:12:27 +0000 (17 09:12 +0800)
committerwanglei <wanglei@loongson.cn>
Thu, 17 Nov 2022 01:25:10 +0000 (17 09:25 +0800)
treed44774bf3480b601567c34dd648f68b0399d3275
parent1310aa168879f78bc202fad0781b5aaef44e5fa6
[LoongArch] Transfer MI flags when expand PseudoCALL

When expanding a PseudoCALL, the corresponding flags (e.g. nomerge)
need to be passed to the new instruction.

This patch also adds test for the nomerge attribute.

The `nomerge` attribute was added during `LowerCall`, but was lost
during expand PseudoCALL. Now add it back.

Reviewed By: SixWeining

Differential Revision: https://reviews.llvm.org/D137888
llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp
llvm/test/CodeGen/LoongArch/nomerge.ll [new file with mode: 0644]