Intel i960 User Manual page 270

Processor compiler
Hide thumbs Also See for i960:
Table of Contents

Advertisement

Language Implementation
If you do not specify a name in the
name of the
function. For example, calling the following as
asm
results in a call to an external function named
select(3)
asm int select (int i)
{
% const(-2:2) i;
. . .
% call select;
}
Any lines of template text following a
compiler error.
If the control line does not contain
inserts the selected template in the assembly-language output in place
of the
function call.
asm
Declarations
The control line can declare the following:
parameters, including return
local temporary variables
labels
Parameter declarations and local temporary declarations are syntactically
identical. If the declared name is the same as a parameter declared in the
function prototype, a parameter is declared. Otherwise, the declaration is
of a local temporary variable.
In the template text, the compiler replaces the name of any declared
parameter with the corresponding register or literal argument. The
keyword becomes the name of the register in which the return
return
value of the
function is expected. The compiler replaces the name of
asm
any local variable with the name of an available register.
You can use a
reglit
integer aggregate containing up to four general-purpose registers, as
declared on the control line. To select a register, specify an integer in
control, the compiler uses the
call
call
or
call
or
class parameter or local variable as an
tmpreg
:
select
control line result in a
, the compiler
error
7
7-81

Advertisement

Table of Contents
loading

Table of Contents