libbpf / blazesym

blazesym is a library for address symbolization and related tasks
BSD 3-Clause "New" or "Revised" License
119 stars 25 forks source link

Add `*_sorted` variants of symbolization APIs #224

Closed danielocfb closed 7 months ago

danielocfb commented 1 year ago

We should add *_sorted variants similar to what we have for the address normalization APIs https://github.com/libbpf/blazesym/blob/21498b6667d13a8784488ece8e57a5ab66717c3c/src/normalize/normalizer.rs#L358-L378

to the symbolization logic here: https://github.com/libbpf/blazesym/blob/21498b6667d13a8784488ece8e57a5ab66717c3c/src/symbolize/symbolizer.rs#L208-L210

That would mean introducing and implementing such a new function, adding tests, and exposing it through C bindings.

SamantaTarun commented 1 year ago

I'd like to look into this.

d-e-s-o commented 1 year ago

I'd like to look into this.

Awesome! Please let me know if you have any questions.

danielocfb commented 1 year ago

@tarunsamanta2k20 do you need any help with this task?

SamantaTarun commented 1 year ago

Let me do it.

SamantaTarun commented 1 year ago

Let me check once.

danielocfb commented 1 year ago

No movement; putting this issue back up for grabs then.

d-e-s-o commented 7 months ago

I looked at this and while it's certainly possible to implement and conceptually makes sense, in reality the performance benefit is probably miniscule, given that symbolization itself is not cheap and sorting a few addresses is unlikely to move the needle. And it really only provides a benefit for process symbolization anyway. Let's put this task on hold until we have a true need, given the anticipated increase in code complexity.