Skip to content
Commit 4921ce21 authored by Eric Ackermann's avatar Eric Ackermann Committed by Benjamin Cabé
Browse files

tests: llext: Add RISC-V CB-Type edge case test



All immediates in RISC-V are encoded as two's complement. This commit
adds a test for relocating jumps that utilize the full range of the
immediate, in both positive and negative direction.
To this end, the test uses the compressed b-type (CB) instruction to
branch to its maximum negative (-256) and maximum positive (+254)
targets.
In case of test failure, expect relocating the corresponding llext to
fail.

Signed-off-by: default avatarEric Ackermann <eric.ackermann@cispa.de>
parent 2d3390f8
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment