Re: IA64 versus effective stack limit - Mailing list pgsql-hackers

From Tom Lane
Subject Re: IA64 versus effective stack limit
Date
Msg-id 25027.1289078116@sss.pgh.pa.us
Whole thread Raw
In response to Re: IA64 versus effective stack limit  (Greg Stark <gsstark@mit.edu>)
List pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> On Sat, Nov 6, 2010 at 5:34 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> As I said above, I don't know of any good way to measure register stack
>> depth directly. �It's probably possible to find out by asking the kernel
>> or something like that, but we surely do not want to introduce a kernel
>> call into check_stack_depth().

> It seems more likely it would be some kind of asm than a trap. This
> might be wishful thinking but is it too much to hope that glibc
> already exposes it through some function?

Yeah, I suppose some asm might be a possible solution, but I was a bit
discouraged after reading some Intel documentation that said that the
register-stack top wasn't exposed in the architectural model.  You
apparently can only find out what's been spilled to memory.  (But
perhaps that's close enough, for the purposes here?)
        regards, tom lane


pgsql-hackers by date:

Previous
From: Greg Stark
Date:
Subject: Re: IA64 versus effective stack limit
Next
From: Tom Lane
Date:
Subject: Re: IA64 versus effective stack limit