Re: feature tests for pthreads implementation and configuration?



In article <44295B83.748ED644@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Kasper Dupont <32013571368912025171@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
Mikael Pettersson wrote:

A no-no, yes, but not a bigger one. Our JITed code runs on stacks
that grow as needed via compiler-inserted overflow checks. That's
why signal handlers (C code not following this protocol) must be
redirected to alt stacks.

Couldn't the overflow check discover large stack usage early
enough to ensure there would still be enough space available
for a signal? (I guess you can figure out what the maximum
stack usage for your handlers is).

No we can't know with 100% accuracy which signals are being
caught or what their handlers are up to.

I'm not saying which solution is the best, just that you
should consider all options.

We have considered over-sized stacks, but their increased memory
consumption characteristics make them less appealing than alt
stacks for us.
--
Mikael Pettersson (mikpe@xxxxxxxxx)
Computing Science Department, Uppsala University
.



Relevant Pages