Title: | DEC Ada |
Notice: | Ada is no longer a trademark of the US Government |
Moderator: | KMOOSE::CMCCUTCHEON |
Created: | Mon Jan 27 1986 |
Last Modified: | Fri Jun 06 1997 |
Last Successful Update: | Fri Jun 06 1997 |
Number of topics: | 3874 |
Total number of notes: | 16668 |
Hi, Using the GET_TASK_INFO package, I know how to obtain the current task's stack size, whith TOP := GET_TASK_INFO.GET_CURRENT_TASK_STACK_TOP; BAS := GET_TASK_INFO.GET_CURRENT_TASK_STACK_BASE; SIZ := BAS - TOP; This value is the same as shown with ada_debug> show -f 4 But I don't know how to obtain the current "Stack in use:" ? Running DEC ADA.V3.3 on an Unix V4.0A system. Thanks for help. Philippe.
T.R | Title | User | Personal Name | Date | Lines |
---|---|---|---|---|---|
3845.1 | use the CMA interface | FLOYD::YODER | MFY | Fri Feb 21 1997 10:36 | 8 |
There doesn't seem to be a routine in the PAL for this. An unsupported method is to use pragma Interface(C, ...) to get at the CMA routines directly--this is unsupported because, in theory, we might someday rewrite the RTL to use the POSIX interface rather than CMA. That is unlikely, but it is an option we will (probably) never officially give up. If you use this, be aware that passive tasks in effect borrow the stacks of their callers (there isn't always a 1-1 map from tasks to stacks). | |||||
3845.2 | correction | FLOYD::YODER | MFY | Fri Feb 21 1997 10:59 | 4 |
I have just realized that the advice in .1 is probably bad... there shouldn't be any reason you can't use the POSIX interface rather than the CMA interface for this particular operation. The CMA interface is just layered on it, and using the POSIX interface would keep working if we recoded the Ada RTL. |