Thread (4 messages) 4 messages, 3 authors, 2005-08-24

Re: GDB backtrace and signal trampolines

flat view

From: Hollis Blanchard <hidden>
Date: 2005-08-12 13:58:32

On Aug 12, 2005, at 12:06 AM, Anton Blanchard wrote:
quoted
Would it make sense to limit the test to within a few hundred bytes of
the stack pointer? Or some better way to detect that the PC is in a
signal trampoline?
With recent kernels we should be able to use the dwarf2 unwind
information in the vdso I think.
I guess compatibility with older kernels will still need to be maintained, though.

I see this note in arch/ppc64/mm/fault.c:
        /*
         * N.B. The POWER/Open ABI allows programs to access up to
         * 288 bytes below the stack pointer.
         * The kernel signal delivery code writes up to about 1.5kB
         * below the stack pointer (r1) before decrementing it.
         * The exec code can write slightly over 640kB to the stack
         * before setting the user r1.  Thus we allow the stack to
         * expand to 1MB without further checks.
         */

So would 2KB be a reasonable limit to the signal frame check, as I described before?

-- 
Hollis Blanchard
IBM Linux Technology Center
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help