beautypg.com

5 pass, 6 proc, Pass – Avago Technologies LSI53C1010 User Manual

Page 130: Proc

background image

4-10

Using the LSI Logic Assembler NASM™

4.6.5 PASS

PASS allows the programmer to pass a “C” element unaltered to the
SCRIPTS output file and on to the “C” compiler. Using this option avoids
the need for run time patching of the addresses of SCRIPTS objects.
PASS is typically used for two types of “C” elements; either an include
statement or a literal string.

4.6.6 PROC

PROC builds output arrays with names other than the generic array
name

SCRIPT

that NASM normally assigns to SCRIPTS opcode arrays.

This is useful when more than one SCRIPTS file is used in a driver
program. It also allows several output arrays to be created with specific
code segments in each one. When SCRIPTS storage space is limited,

Syntax

EXTERN label [, label ...] or
EXTERN label = data_specifier [, label =
data_specifier...]
a data specifier is:
{byte_val[, byte_val]} or count{byte_val | ??}

Fields

A count is any valid constant with a value between 0 and
64 Kbytes.

Example

EXTERN buffer; a buffer in the driver
EXTERN buffer=1024{??}; same buffer, but now

; the debugger will have
; information about space
;

requirements

Description The first form of the EXTERN syntax is only provided for

compatibility with older versions of the SCRIPTS compiler. The
second form (with space requirements information for the
debugger) should be used in all new programs. Declarative
instructions never allocate memory, but give the debugger or driver
code the information required to allocate the memory.

Syntax

PASS(element)

Examples

Include statement: PASS(include”SCRIPTS.h”)
Literal string: Wait Reselect PASS(&alt_addr)

Description

PASS tells NASM to pass everything between the left and right
parentheses on to the output file, literally. Therefore, the passed
statements can be read by the “C” compiler.

This manual is related to the following products: