Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Скачиваний:
50
Добавлен:
14.04.2015
Размер:
1.37 Mб
Скачать

C51 Compiler

227

 

 

Variable-length Argument List Routines

Routine

Attributes

Description

va_arg

reentrant

Retrieves an argument from an argument list.

va_end

reentrant

Resets an argument pointer.

va_start

reentrant

Sets a pointer to the beginning of an argument list.

The variable-length argument list routines are implemented as macros and are defined in the STDARG.H include file. These routines provide you with a portable method of accessing arguments in a function that takes a variable number of arguments. These macros conform to the ANSI C Standard for variable-length argument lists.

Miscellaneous Routines

Routine

Attributes

Description

setjmp

reentrant

Saves the current stack condition and program address.

longjmp

reentrant

Restores the stack condition and program address.

_nop_

intrinsic,

Inserts an 8051 NOP instruction.

 

reentrant

 

_testbit_

intrinsic,

Tests the value of a bit and clears it to 0.

 

reentrant

 

Routines found in the miscellaneous category do not fit easily into any other library routine category. The setjmp and longjmp routines are implemented as functions and are prototyped in the STDJMP.H include file.

The _nop_ and _testbit_ routines direct the compiler to generate an NOP instruction and a JBC instruction respectively. These routines are prototyped in the INTRINS.H include file.

8

Соседние файлы в папке HLP