Directives

Jupiter supports most common assembler directives, including some indicated here.

.file

Emits filename.

Usage

.file <filename>

Example

.file "/home/ubuntu/Desktop/lab10.s"

Arguments

  • filename: quoted filename

Aliases

  • none

.zero

Reserves the specified number of bytes.

Usage

Example

Arguments

  • value: (should be > 0)

Aliases

  • .space

.string

Stores the string and adds null terminator.

Usage

Example

Arguments

  • string: quoted string

Aliases

  • .asciiz, .asciz

.ascii

Stores the string and does not add null terminator.

Usage

Example

Arguments

  • string: quoted string

Aliases

  • none

.byte

Store the listed value(s) as 8 bit bytes.

Usage

Example

Arguments

  • list: 8-bit comma separated bytes

Aliases

  • none

.half

Store the listed value(s) as 16-bit half words.

Usage

Example

Arguments

  • list: 16-bit comma separated half words

Aliases

  • .short, .2byte

.word

Store the listed value(s)/symbol(s) as 32 bit words.

Usage

Example

Arguments

  • list: 32-bit comma separated words or comma separated symbols

Aliases

  • .long, .4byte

.float

Store the listed value(s) as 32 bit float values.

Usage

Example

Arguments

  • list: 32-bit comma separated float words

Aliases

  • none

.align

Align next data item to a power of 2 byte boundary.

Usage

Example

Arguments

  • alignval: integer, should be >= 0

Aliases

  • .palign

.balign

Align next data item to a byte boundary.

Usage

Example

Arguments

  • alignval: integer, should be > 0

Aliases

  • none

.globl

Store the symbol in the global symbol table.

Usage

Example

Arguments

  • symbol: symbol to store in global symbol table

Aliases

  • .global

.section

Emits the specified section and makes it the current section.

Usage

Example

Arguments

  • section: {.text, .data, .rodata, .bss}

Aliases

  • none

.data

Emits data section and makes it the current section.

Usage

Example

Arguments

  • none

Aliases

  • none

.text

Emits text section and makes it the current section.

Usage

Example

Arguments

  • none

Aliases

  • none

.rodata

Emits read-only data section and makes it the current section.

Usage

Example

Arguments

  • none

Aliases

  • none

.bss

Emits bss section and makes it the current section.

Usage

Example

Arguments

  • none

Aliases

  • none

Last updated

Was this helpful?