Open System Services System Calls Reference Manual (G06.25+, H06.03+)
tdm_spawnp(2) OSS System Calls Reference Manual
pe_heap_max Specifies the maximum size of the heap in bytes for the new process if it is a
native process.
See the C/C++ Programmer’s Guide description of the HEAP pragma for gui-
dance on the use of nonzero values for this field.
If a value is specified for this field for G-series TNS or accelerated object files,
the specified value is ignored.
pe_space_guarantee
Specifies the minimum available swap space to guarantee for the new process.
If the calling process specifies a value, the value must be less than or equal to a
multiple of the page size of the processor in which the new process will run.
Values less than a multiple of the page size are rounded up to the next multiple
of the page size. If the parent process specifies a nonzero value, that value is |
used for the child process; otherwise, the child process inherits the space guaran- |
tee attribute of the parent process.
If the new process requires a guarantee of available swap space and the system
cannot guarantee the required amount, the function call fails, and errno is set to
the value of [EAGAIN].
If a value is specified for this field for G-series TNS or accelerated object files,
the specified value is used for the main stack of the new process.
For detailed information about Guardian process attributes, see the PROCESS_LAUNCH_ pro-
cedure in the Guardian Procedure Calls Reference Manual.
Output Structure Information
If the pr_results parameter does not contain a null pointer, it points to an output structure defined
in the tdmext.h header file. This structure can contain fields that vary from RVU to RVU,
including reserved and filler fields.
First, the output structure must be initialized by using the #define
DEFAULT_PROCESS_EXTENSION_RESULTS. This initialization sets the value of the
pr_len field to the correct value for the current RVU. The value of the pr_len field should not be
modified after being set by #define DEFAULT_PROCESS_EXTENSION_RESULTS.
The process_extension_results output structure is described in the
process_extension_results(5) reference page.
EXAMPLES
This example uses the tdm_spawnp() function to perform I/O redirection in a new process:
if ((NewStdOut = open ("newout", ...)) != -1)
/* process the error */
fd_map[0] = 0;
fd_map[1] = NewStdOut;
fd_map[2] = 2;
fd_count = 3;
tdm_spawnp(..., fd_count, fd_map, ...);
close(NewStdOut);
8−68 Hewlett-Packard Company 527186-003