Skip to content

feat: debug info - #27

Open
AndrewJackson2020 wants to merge 2 commits into
masterfrom
postgres_debug_symbols
Open

AndrewJackson2020 wants to merge 2 commits into
masterfrom
postgres_debug_symbols

Conversation

@AndrewJackson2020

Copy link
Copy Markdown
Contributor

No description provided.

@AndrewJackson2020
AndrewJackson2020 requested a review from a team as a code owner November 17, 2026 03:49
Comment on lines +275 to +278
# get debug line numbers into binaries
for f in $out/bin/*; do
dsymutil "$f"
done

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you elaborate on why is this needed?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My understanding (sourced entirely from Claude) is that on Macos/Clang symbols in binaries really just means keep a map in the binary to the corresponding .o file which contains the actual line number information. Once the .o files are removed all line level debug info is gone. This is needed because it modifies the binary to store all of the line number info together with the binary.

That said this is all new to me and I'm open to better ways go doing this.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, but have you confirmed this is necessary?

Ideally we'd have some sort of test for this but a manual test would do fine.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm it was not working before I input those lines and it was working after I input those lines. Agreed a real test would be better, in fact our UBSAN/ASAN tests caught a regression when I tried implementing this functionality. I'm not a huge fan as to how our tests work currently though (each assertion is a single step in a gh action pipeline).

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