DynamoRIO / DynamoRIO/dynamorio

drsym_lookup_address should not return Arm mapping symbols

Open
#5,646 3 comments 0 reactions 0 assignees View on GitHub
Component-API Component-Extension help wanted
Dominant language
C
Stars
3.2k
Forks
629
Avg merge
2d 15h
Merged PRs (30d)
31

Description

Arm and AArch64 ABIs extend ELF with code mapping symbols to disambiguate code and data (and in the case of AArch32, they disambiguate Arm and Thumb). Symbols are generally $a, $t, $x and $d possibly extended with a suffix .xxxx.

What we are seeing is that diagnostics that call drsym_lookup_address() to find the function containing some address of interest, are (on Arm/Arm64) sometimes finding mapping symbols. This function should ignore mapping symbols. This would give consistent behavior across Arm and non-Arm architectures.

The mapping symbols might be useful for a query like "is this address Arm, Thumb, Arm64 or a literal pool?" but that's a different sort of query.

Basically, the mapping symbols aren't proper symbols, they are just there for technical reasons because that was a way to mark places in ELF - they could equally well have been relocations.

Seen on 9.0.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.