Keil Logo Arm Logo

Program Objects

Program objects include the code generated for C program functions by the Cx51 Compiler. Each function in a source module is assigned a separate code segment using the ?PR?function_name?module_name naming convention. For example, the function error_check in the file SAMPLE.C would result in a segment name of ?PR?ERROR_CHECK?SAMPLE.

Names for reentrant functions and functions with register parameters are prefixed with special characters to differentiate them from standard functions and to avoid run-time errors when invoking them.

  • void func (void) ...
    
    Names of functions that have no arguments or whose arguments are not passed in registers are not modified. This example has a name of FUNC and a segment name of ?PR?FUNC?FILENAME.
  • void func1 (char x) ...
    
    Names of functions whose arguments are passed in registers are prefixed with the underscore character ('_'). This example has a name of _FUNC1 and a segment name of ?PR?_FUNC1?FILENAME.
  • void func2 (void) reentrant ...
    
    Names of reentrant functions are prefixed with "_?". This example has a name of _?FUNC2 and a segment name of ?PR?_?FUNC2?FILENAME.

Keil logo

Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.