[PATCH 5/7] RISC-V: fix auipc-jalr addresses in patched alternatives

Lad, Prabhakar prabhakar.csengg at gmail.com
Tue Nov 22 02:59:57 PST 2022


Hi Heiko,

On Mon, Nov 21, 2022 at 10:17 PM Heiko Stübner <heiko at sntech.de> wrote:
>
> Am Montag, 21. November 2022, 22:31:36 CET schrieb Lad, Prabhakar:
> > Hi Heiko,
> >
<snip>
> As either manually or with a helper like
>
>         https://luplab.gitlab.io/rvcodecjs/#q=0xf4c080e7
>
> you can then decode the actual instruction and compare.
>
> In your log the two jalr instructions decode to different offsets,
>         jalr x1, x1, -180
> vs
>         jalr x1, x1, -834
>
> Can you check what the patch_offset value is in your case?
>
patch_offset for the above case is -654.

Cheers,
Prabhakar



More information about the linux-riscv mailing list