Posted Aug 12, 2004 15:10 UTC (Thu) by jmshh
In reply to: Out-of-lining spinlocks
Parent article: Out-of-lining spinlocks
The issue is better solved by the profiling tools, but for
most architectures they don't know how to identify the caller. The missing
item is the return address.
There are two solutions:
- Compile the code with using a frame pointer (FP) for each routine.
For most architectures (especially register starved ones like x86) the
code will be significantly larger and slower.
Analyze the code statically and for every possible PC calculate an offset
from SP where the return address is found. This requires a dissassembler
in the tool.
to post comments)