Skip to content

[ARM] Implement R_ARM_LDR_PC_G1 relocation - #1789

Draft
Steven Ramirez Rosa (Steven6798) wants to merge 1 commit into
qualcomm:mainfrom
Steven6798:issue-1770
Draft

[ARM] Implement R_ARM_LDR_PC_G1 relocation#1789
Steven Ramirez Rosa (Steven6798) wants to merge 1 commit into
qualcomm:mainfrom
Steven6798:issue-1770

Conversation

@Steven6798

Copy link
Copy Markdown
Contributor

Add support for R_ARM_LDR_PC_G1 by sharing the ARM LDR PC-group residual encoding logic and wiring the relocation to the ARM apply table. The implementation extracts the signed LDR literal addend, computes S + A - P, selects the output U bit from the displacement sign, and writes the group residual into the imm12 field with overflow checking.

Add standalone ARM relocation coverage for both a valid R_ARM_LDR_PC_G1 encoding and an overflow case where the group residual does not fit in imm12.

Fix: #1770

Add support for R_ARM_LDR_PC_G1 by sharing the ARM LDR PC-group
residual encoding logic and wiring the relocation to the ARM apply
table. The implementation extracts the signed LDR literal addend,
computes S + A - P, selects the output U bit from the displacement sign,
and writes the group residual into the imm12 field with overflow
checking.

Add standalone ARM relocation coverage for both a valid R_ARM_LDR_PC_G1
encoding and an overflow case where the group residual does not fit in
imm12.

Fix: qualcomm#1770

Signed-off-by: Steven Ramirez Rosa <ramirezr@qti.qualcomm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arm bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ARM] R_ARM_LDR_PC_G1: unsupported

1 participant