Next: Z80 Opcodes, Previous: Z80 Floating Point, Up: Z80-Dependent [Contents][Index]

#### 9.56.4 Z80 Assembler Directives

`as` for the Z80 supports some additional directives for compatibility with other assemblers.

These are the additional directives in `as` for the Z80:

`db expression|string[,expression|string...]`
`defb expression|string[,expression|string...]`

  For each string the characters are copied to the object file, for each other expression the value is stored in one byte. A warning is issued in case of an overflow.

`dw expression[,expression...]`
`defw expression[,expression...]`

  For each expression the value is stored in two bytes, ignoring overflow.

`d24 expression[,expression...]`
`def24 expression[,expression...]`

  For each expression the value is stored in three bytes, ignoring overflow.

`d32 expression[,expression...]`
`def32 expression[,expression...]`

  For each expression the value is stored in four bytes, ignoring overflow.

`ds count[, value]`
`defs count[, value]`

  Fill count bytes in the object file with value, if value is omitted it defaults to zero.

`symbol equ expression`
`symbol defl expression`

  These directives set the value of symbol to expression. If `equ` is used, it is an error if symbol is already defined. Symbols defined with `equ` are not protected from redefinition.

`set`

  This is a normal instruction on Z80, and not an assembler directive.

`psect name`

  A synonym for See Section, no second argument should be given.