1.3.1 Labeling Format
Symbol names beginning with a dot (.) are assumed to be local symbols.
Names beginning with an underscore (_) are reserved by ANSI C.
2.2.2 Statement Syntax
The syntax of an assembly language statement is:
[label:] [instruction]
where:
label
is a symbol name.
instruction
is an encoded pseudo-op, synthetic instruction, or instruction.
2.3.2 Comments
A comment is preceded by an exclamation mark character (!); the exclamation mark
character and all following characters up to the end of the line are ignored. C
language-style comments (‘‘/*…*/’’) are also permitted and may span multiple lines.
2.3.3 Labels
A label is either a symbol or a single decimal digit n (0…9). Alabel is immediately followed by a colon (:). Numeric labels may be defined repeatedly in an assembly file; normal symbolic labels may be defined only once. Anumeric label n is referenced after its definition (backward reference) as nb, and before its definition (forward reference) as nf.
2.3.7 Special Symbols -Registers
%lo Extractsleastsignificant10bits
%hi Extractsmostsignificant22bits
Pseudo-Operations
A.1 Alphabetized Listing with Descriptions
.global symbol [, symbol]* .globl symbol [, symbol]*
Declares each symbol in the list to be global; that is, each symbol is either defined
externally or defined in the input file and accessible in other files; default bindings
for the symbol are overridden.
- A global symbol definition in one file will satisfy an undefined reference to the same global symbol in another file.
- Multiple definitions of a defined global symbol is not allowed. If a defined global symbol has more than one definition, an error will occur.
- A global psuedo-op oes not need to occur before a definition, or tentative definition, of the specified symbol.
.word 32bitval [, 32bitval]*
Generates (a sequence of) initialized words in the current segment.
reference:
SPARC Assembly Language Reference Manual
链接:https://pan.baidu.com/s/1OSbqXMWnQGT4Yxo29be1pw
提取码:alej
复制这段内容后打开百度网盘手机App,操作更方便哦