liballocs icon indicating copy to clipboard operation
liballocs copied to clipboard

Make use of LLVM allocation site information in DWARF

Open stephenrkell opened this issue 11 months ago • 4 comments

https://github.com/llvm/llvm-project/pull/132073

We can and should use this information although I suspect it won't absolve us from analysing sizeof around allocation sites at least in some cases, e.g. wrapper functions.

Thanks @jryans for flagging this addition.

stephenrkell avatar Apr 01 '25 19:04 stephenrkell

FYI, with that PR applied, allocation site information is mostly only created for C++ new operators. (Though I am looking to also add sizeof support.)

thejh avatar Apr 03 '25 15:04 thejh

FYI, with that PR applied, allocation site information is mostly only created for C++ new operators. (Though I am looking to also add sizeof support.)

Understood, and thanks for the tip-off! Just operator new is useful already, but adding sizeof support would be great. Section 4 in this paper describes how I did it in my side-band (out-of-DWARF) solution....

stephenrkell avatar Apr 05 '25 19:04 stephenrkell

[Leaving a note for my future self here.]

alethkit avatar Nov 12 '25 12:11 alethkit