Skip to content

Commit

Permalink
Add debug info to elp
Browse files Browse the repository at this point in the history
Summary:
Users reported instances of ELP being repeatedly slow (eg T196163271). To ease troubleshooting, we can add debug-info when building elp. This allows us to dump a backtrace of all threads of a problematic ELP instance by running:

```
ps aux | grep "elp server" | grep -v grep | awk '{print $2}' | xargs -I{} lldb-stable -p {} --batch -o 'thread backtrace all' > /tmp/debug.txt
```

Using the "line-tables-only" option ensures we only add the minimum amount of debug info we need, including filename/line number info, but no variable or function parameter info.

With the above changes the executable jumps from 41Mb to a whopping 141Mb, but I think we can live with it, at least until we find the root-cause of the slowness.

Reviewed By: alanz

Differential Revision: D61378510

fbshipit-source-id: bdbd5bcc738cf709452643d42e3f446c20290a13
  • Loading branch information
robertoaloi authored and facebook-github-bot committed Aug 16, 2024
1 parent 31cb05e commit 334bfd1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ xtask = "run --package xtask --"

[profile.release]
lto = "thin"
strip = true
debug = "line-tables-only"

# Workaround to easily locate workspace root
# See https://github.com/rust-lang/cargo/issues/3946
Expand Down

0 comments on commit 334bfd1

Please sign in to comment.