[llvm-dev] workaround to force LLD to make dwarf info sections mappable/loadable?
Andrew Kelley via llvm-dev
llvm-dev at lists.llvm.org
Mon Dec 3 14:24:49 PST 2018
On 12/3/18 5:10 PM, Rui Ueyama wrote:
> I think Eli made a good point.
Eli's point seems to be "your use case is not valid", which I will
consider, but it doesn't really work towards solving the problem as stated.
> In addition to that, if you are writing a
> OS kernel, I guess you are also writing a loader, so you can map
> anything as you want, no?
Well, I don't have a loader written yet, and I want to use this stack
trace feature while working on it. But even if I did, the addresses in
the ELF file produced by LLD are incoherent, and so it would not be
possible to map them.
Another alternative would be to ship debug symbol files separately on a
file system. I also don't have a file system written yet.
The bottom line is that, there's no fundamental reason this cannot work;
it is a quirk of conventions that is unnecessarily preventing the debug
info from being mapped into memory.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 833 bytes
Desc: OpenPGP digital signature
More information about the llvm-dev