How to get the SS:ESPs of Main Process and Threads

Hello everybody,

I had a question that’s been bugging me for some time. Specifically, how do
I get the SS:ESP values for main process threads while the execution is in a

I think in QNX4, some functions like qnx_get… but they did not appeared in
QNX 6.2.

Any suggestion is appreciated.