Some of the MARS and Spim assembler directives are listed on the right:
|
|
Directive |
Description |
.text |
Put next code into text section. |
.data |
Put next code into data section. |
.globl name |
Make name be a global symbol. |
.space n |
Allocate n bytes of space. |
.word val1, val2, ... |
Allocate one word for each value. |
.half val1, val2, ... |
Allocate a halfword for each value. |
.byte val1, val2, ... |
Allocate a byte for each value. |
.ascii "string" |
Allocate space for the ASCII characters. |
.asciiz "string" |
Allocate space for string, NULL terminated. |
.align n |
Start next on 2n byte boundary. |
|