pxfsysconf
- Date:
10-20-2011
NAME
PXFSYSCONF - Retrieves the value of configurable system variables
SYNOPSIS
INTEGER name, ival, ierror
CALL PXFSYSCONF(name, ival, ierror)
STANDARDS
IEEE Std 1003.9-1992 standard interface for FORTRAN 77
DESCRIPTION
The PXFSYSCONF routine uses the sysconf(2) function to retrieve the current value for the name configurable system variable.
All arguments must be of default kind unless documented otherwise. Default kind is KIND=4 for integer, real, complex, and logical arguments.
This routine has the following arguments:
- name
An input integer variable or array element containing the integer value of a symbolic constant for one of the following configurable system variables defined in POSIX Std. 1003.1, section 4.8.1.2:
ARG_MAX
CHILD_MAX
CLK_TCK
NGROUPS_MAX
OPEN_MAX
STREAM_MAX
TZNAME_MAX
_POSIX_JOB_CONTROL
_POSIX_SAVED_IDS
_POSIX_VERSION
The integer value for each of these symbolic constants is retrieved through the use of PXFCONST or IPXFCONST. The integer values may be combined through the use of a bitwise inclusive OR function.
- ival
An output integer variable that will contain the value of the system variable name.
- ierror
An output integer variable that contains zero if PXFSYSCONF was successful or nonzero if name is an invalid system variable.
EXAMPLES
In this example, PXFSYSCONF will retrieve the value of the CLK_TCK system variable.
program test
integer ival, ierror, iclktck
ival = 0
iclktck = 0
CALL PXFCONST ('CLK_TCK',iclktck,ierror)
if (ierror.ne.0) then
print *,'FAIL: error from pxfconst = ',ierror
goto 9999
endif
CALL PXFSYSCONF (iclktck, ival, ierror)
if (ierror.ne.0) then
print *,'FAIL: error from pxfsysconf = ',ierror
else
print *,'PASS: error from pxfsysconf = ',ierror
endif
print *, 'CLK_TCK=',ival
9999 continue
end
SEE ALSO
sysconf(2)
PXFCONST(3F)