User-Level Native Thread Primitives (GThread) Library White Paper (G06.26+)
User-Level Native Thread Primitives (GThread Library)  03/31/2005 
Hewlett-Packard Company--540065-001    Page 17 of 46 
2.8.  TNS/E Migration Aid 
GTH_GET_ESTIMATED_STACK_SIZE_( int32 sizeEstimate ) 
Description: 
Provides the caller with a TNS/E adjusted stack size given an estimated TNS/R size. Callable for 
either static or swapped threads. 
Input: 
SizeEstimate - Estimated size in bytes; size provided must be based on a TNS/R implementation. 
Return: int32 
Returns the estimated stack size in bytes. 
Considerations: 
Use of this interface is optional. The client is free to derive the appropriate stack size for the target 
platform by other means. 
This interface should be called prior to stack space allocation and thread creation 
(GTHREAD_INITIATE_) to determine the appropriate stack size based on the host platform. 
If called on a TNS/R host or in a TNS (non-native) process, the interface returns sizeEstimate (no 
resizing necessary). 










