Skip to content

Add support for 64-bit addresses#51

Open
dredfern-zoox wants to merge 1 commit intoHBehrens:masterfrom
dredfern-zoox:master
Open

Add support for 64-bit addresses#51
dredfern-zoox wants to merge 1 commit intoHBehrens:masterfrom
dredfern-zoox:master

Conversation

@dredfern-zoox
Copy link

The regex in collector.py currently assumes that the memory addresses output by nm are 8-characters wide (e.g. 32-bit addresses). Update the regex to accept any number of characters between 8 and 16 (to support 64-bit addresses).

Minimal test example using a 64-bit host machine and toolchain (shows no symbols on current master, but finds symbols on this commit):

echo "int main() { return 0; }" > test.cpp
g++ test.cpp   # uses host gcc tools (64-bit Linux) but same result for AARCH64 compilers
puncover --gcc_tools_base /usr/bin/ --elf ./a.out --src_root . --build_dir .

I'm not sure whether the regexes to parse assembly lines will also need updating in the future; the platform I'm working on does not have any disassembly wider than 9 characters. I did update the assembly addresses, though, and also added test cases for both address types.

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.

2 participants