binutils Newspaper
JUNE 15, 2026
aarch64 Proposed

Aarch64: Add explicit all-nil qualifers to opcode table

Make the `NIL` qualifier value explicit in qualifier sequences to avoid relying on its implicit zero value.

This patch updates the opcode table to explicitly define all-NIL qualifier sequences. The AARCH64_OPND_QLF_NIL qualifier will soon have a nonzero enum value. This change ensures that qualifier sequences that are intended to be all-NIL are explicitly defined as such, rather than relying on the implicit zero value of uninitialized memory. This prevents unexpected behavior when AARCH64_OPND_QLF_NIL changes.

In Details

In the AArch64 backend, the opcode table (opcodes/aarch64-tbl.h) defines the structure of AArch64 instructions. This patch introduces QL_0, QL_NIL1, QL_NIL2, and QL_NIL3 macros for explicitly defining qualifier sequences containing AARCH64_OPND_QLF_NIL. This ensures correct behavior when AARCH64_OPND_QLF_NIL is no longer implicitly zero.

For Context

The assembler uses opcode tables to understand the structure of instructions. This patch makes the table more explicit about what happens when an instruction doesn't have a qualifier. Instead of assuming a default value of zero, it explicitly sets the qualifier to NIL. This ensures that the assembler continues to work correctly even if the internal value of NIL changes in the future.

Filed Under: aarch64assembleropcode tablequalifierNIL