Skip to content

i#3544: RV64: Support RISC-V ELF in module_get_platform()#7247

Merged
ziyao233 merged 4 commits intoDynamoRIO:masterfrom
ziyao233:rv64/linux-execve-null
Feb 6, 2025
Merged

i#3544: RV64: Support RISC-V ELF in module_get_platform()#7247
ziyao233 merged 4 commits intoDynamoRIO:masterfrom
ziyao233:rv64/linux-execve-null

Conversation

@ziyao233
Copy link
Copy Markdown
Member

@ziyao233 ziyao233 commented Feb 4, 2025

Differing from x86 and ARM, 32-bit and 64-bit variants of RISC-V share the same e_machine constant EM_RISCV, thus additional check against e_ident is required to obtain the bitwidth.

This fixes test linux.execve-null on riscv64, where DynamoRIO wrongly assumes an execve call to a RISC-V ELF will fail, thus loses control of the child process. The test fails on QEMU so isn't enabled in CI for now.

Issue: #3544

Differing from x86 and ARM, 32-bit and 64-bit variants of RISC-V share
the same e_machine constant EM_RISCV, thus additional check against
e_ident is required to obtain the bitwidth.

This fixes test linux.execve-null on riscv64, where DynamoRIO wrongly
assumes an execve call to a RISC-V ELF will fail, thus loses control of
the child process.

Issue: DynamoRIO#3544
@ziyao233 ziyao233 requested a review from ksco February 4, 2025 19:06
@ksco ksco requested a review from derekbruening February 6, 2025 05:03
@ziyao233 ziyao233 merged commit b25c95f into DynamoRIO:master Feb 6, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants