[objdump][ARM] Fix evaluating the target address of a Thumb BLX(i)
authorIgor Kudrin <ikudrin@accesssoftek.com>
Fri, 18 Jun 2021 03:40:55 +0000 (10:40 +0700)
committerIgor Kudrin <ikudrin@accesssoftek.com>
Fri, 18 Jun 2021 03:40:55 +0000 (10:40 +0700)
commit85ec21075100049ea8b8e5f945628ae2adae628e
treecbc193ee6581772e463da0f4bfb0988fc53dc0c2
parenta10aeb3b32b5f935528ba41d7b7ee18e8d79d9e2
[objdump][ARM] Fix evaluating the target address of a Thumb BLX(i)

The instruction can be 16-bit aligned while targeting 32-bit aligned
code. To calculate the target address correctly, the address of the
instruction has to be adjusted.

Differential Revision: https://reviews.llvm.org/D104446
llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp
llvm/test/tools/llvm-objdump/ELF/ARM/tblxi-target.s [new file with mode: 0644]