Summary of Subsystem Library Functions

Those IBM C and C++ Compilers library functions that require a run-time environment cannot be used in a subsystem. The subsystem libraries contain the library functions that do not require a runtime environment, including the extensions that allow low-level I/O. No other I/O functions are provided.

With the exception of the memory allocation functions (calloc, malloc, realloc, and free), all of the functions in the subsystem libraries are reentrant.

Note: Although the low-level I/O functions defined in <io.h> are reentrant, you should serialize access to these functions within each file. If you do not serialize the access, you may get unexpected input or output.

Subsystem Library Functions

abort

abs

access

atof

atoi(1)

atol(1)

atold

atoll

bsearch

calloc

chmod

_chsize

_clear87

close

_control87

creat

_debug_calloc

_debug_free

_debug_heapmin

_debug_malloc

_debug_realloc

_debug_ucalloc

_debug_uheapmin

_debug_umalloc

div

_dump_allocated_delta

_dump_allocated

dup

dup2

__eof

exit(2)

_filelength

_fpreset

free

_heap_check

_heap_walk

_heapchk

_heapmin

_heapset

isatty

_itoa

labs

llabs

ldiv

lldiv

longjmp(3)

lseek

_ltoa

malloc

memchr

memcmp

memcpy

memmove

memset

_mheap

_msize

open

printf(4)

qsort

read

realloc

realloc

_set_crt_msg_handle

setjmp(3)

_setmode

_sopen

sprintf(4)

sscanf(4)

_status87

strcat

strchr

strcmp

strcpy

strcspn

strdup

strncat

strncmp

strncpy

strpbrk

strrchr

strspn

strstr

strtol

strtoul

strtoull

_tell

_uaddmem

_ucalloc

_uclose

_ucreate

_udefault

_udestroy

_udump_allocated

_udump_allocated_delta

_uheap_check

_uheap_walk

_uheapchk

_uheapmin

_uheapset

_ulltoa

_ultoa

_umalloc

umask

_uopen

_ustats

va_arg(5)

va_end(5)

va_start(5)

vprintf(4)

vsprintf(4)

write





Notes:

  1. The subsystem library versions of these functions do not use the locale information that the standard library versions use.
  2. atexit and _onexit are not provided.
  3. You must write your own exception handler when using these functions in a subsystem.
  4. When you use these functions in a subsystem, \n will be translated to \r\n and DosWrite will be used to write the contents of the buffer to stdout. There is no serialization protection and no multibyte support. These functions use only the default "C" locale information.
  5. These functions are implemented as macros.
  6. va_start is mapped to the built-in __va_start, va_end is mapped to __va_arg, a library function, and va_end is mapped to do-nothing. For portability, you must use the va_start, va_arg, and va_end versions.


Subsystem Libraries