gtpa2m39Application Programming

TPF Application Program Interface Functions

This chapter discusses macros and functions that perform similar operations. The discussion only mentions functions, but the same points are true also for macros unless specifically described otherwise.

Refer to Language Structures and Case Guidelines for an understanding of why we provide both assembly language and C language structures in some cases and only C language structures in others.

The environment of an application program is the conceptual layer between the program and the TPF system. The environment is created when the system initially loads (IPLs) and its characteristics (such as the date, locale, libraries, and access to system resources) come from aspects of system operation. When the C library is brought into memory during restart, it is part of the environment and available to be shared by all C programs. The environment is implicit in each ECB by default even though the associated C structures are not physically allocated.

Environments are important because the ISO-C environment is different from the TARGET(TPF) environment. The TARGET(TPF) environment is composed of system state information a program can access from the TPF system. The ISO-C environment consists of state information provided through library functions and kept in the task communications area (TCA). TARGET(TPF) programs access TPF system structures to determine state information. ISO-C programs access state information in the TCA.