[LoongArch] Modify ParserMethod for the simm26_b operand type
authorwanglei <wanglei@loongson.cn>
Fri, 21 Oct 2022 08:35:23 +0000 (16:35 +0800)
committerWeining Lu <luweining@loongson.cn>
Fri, 21 Oct 2022 09:01:46 +0000 (17:01 +0800)
commit67902920628f889cdef402bb0e8ca7a3df51e25f
tree3194fa41fffb49f1bfd412f14378edfd124bc690
parentbefb731be64a60b97f857d18eaa40d68f8ba792d
[LoongArch] Modify ParserMethod for the simm26_b operand type

Modify the ParserMethod of `simm26_b` operand type to `parseImmediate`.

Before that, for the `simm26_b` operand type, the same ParserMethod
was used as `simm26_bl`. When using the internal assembler to process
the blockaddress with `asm` instruction, the wrong blockaddress symbol
would be generated due to the call to the `getOrCreateSymbol()`
interface.

Differential Revision: https://reviews.llvm.org/D136073
llvm/lib/Target/LoongArch/LoongArchInstrInfo.td
llvm/test/CodeGen/LoongArch/blockaddress-symbol.ll [new file with mode: 0644]