@@ -10,10 +10,10 @@ AMDGPU Instructions Notation
1010Introduction
1111============
1212
13- This is an overview of notation used to describe syntax of AMDGPU assembler instructions.
13+ This is an overview of notation used to describe the syntax of AMDGPU assembler instructions.
1414
15- This notation mimics the :ref: `syntax of assembler instructions<amdgpu_syn_instructions> `
16- except that instead of real operands and modifiers it provides references to their description .
15+ This notation looks a lot like the :ref: `syntax of assembler instructions<amdgpu_syn_instructions> `,
16+ except that instead of real operands and modifiers, it uses references to their descriptions .
1717
1818Instructions
1919============
@@ -23,7 +23,9 @@ Notation
2323
2424This is the notation used to describe AMDGPU instructions:
2525
26- ``< ``\ :ref: `opcode description<amdgpu_syn_opcode_notation> `\ ``> < ``\ :ref: `operands description<amdgpu_syn_instruction_operands_notation> `\ ``> < ``\ :ref: `modifiers description<amdgpu_syn_instruction_modifiers_notation> `\ ``> ``
26+ | ``<``\ :ref:`opcode description<amdgpu_syn_opcode_notation>`\ ``>
27+ <``\ :ref:`operands description<amdgpu_syn_instruction_operands_notation>`\ ``>
28+ <``\ :ref:`modifiers description<amdgpu_syn_instruction_modifiers_notation>`\ ``>``
2729
2830.. _amdgpu_syn_opcode_notation :
2931
@@ -42,7 +44,8 @@ Operands
4244
4345An instruction may have zero or more *operands *. They are comma-separated in the description:
4446
45- ``< ``\ :ref: `description of operand 0<amdgpu_syn_instruction_operand_notation> `\ ``>, < ``\ :ref: `description of operand 1<amdgpu_syn_instruction_operand_notation> `\ ``>, ... ``
47+ | ``<``\ :ref:`description of operand 0<amdgpu_syn_instruction_operand_notation>`\ ``>,
48+ <``\ :ref:`description of operand 1<amdgpu_syn_instruction_operand_notation>`\ ``>, ...``
4649
4750The order of *operands * is fixed. *Operands * cannot be omitted
4851except for special cases described below.
6063
6164* *kind * is an optional prefix describing operand :ref: `kind<amdgpu_syn_instruction_operand_kinds> `.
6265* *name * is a link to a description of the operand.
63- * *tags * are optional. They are used to indicate :ref: `special operand properties<amdgpu_syn_instruction_operand_tags> `.
66+ * *tags * are optional. They are used to indicate
67+ :ref: `special operand properties<amdgpu_syn_instruction_operand_tags> `.
6468
6569.. _amdgpu_syn_instruction_operand_kinds :
6670
@@ -70,16 +74,16 @@ Operand Kinds
7074Operand kind indicates which values are accepted by the operand.
7175
7276* Operands which only accept *vector * registers are labelled with 'v' prefix.
73- * Operands which only accept *scalar * values are labelled with 's' prefix.
74- * Operands which accept both * vector * registers and * scalar * values have no prefix.
77+ * Operands which only accept *scalar * registers and values are labelled with 's' prefix.
78+ * Operands which accept any registers and values have no prefix.
7579
7680Examples:
7781
7882.. parsed-literal ::
7983
8084 vdata // operand only accepts vector registers
8185 sdst // operand only accepts scalar registers
82- src1 // operand accepts both scalar and vector registers
86+ src1 // operand accepts vector registers, scalar registers, and scalar values
8387
8488 .. _amdgpu_syn_instruction_operand_tags :
8589
@@ -92,16 +96,16 @@ Operand tags indicate special operand properties.
9296 Operand tag Meaning
9397 ============== =================================================================================
9498 :opt An optional operand.
95- :m An operand which may be used with
96- :ref: `VOP3 operand modifiers<amdgpu_synid_vop3_operand_modifiers > ` or
97- :ref: `SDWA operand modifiers<amdgpu_synid_sdwa_operand_modifiers > `.
98- :dst An input operand which may also serve as a destination
99+ :m An operand which may be used with operand modifiers
100+ :ref: `abs<amdgpu_synid_abs> `, :ref: ` neg<amdgpu_synid_neg > ` or
101+ :ref: `sext<amdgpu_synid_sext > `.
102+ :dst An input operand which is also used as a destination
99103 if :ref: `glc<amdgpu_synid_glc> ` modifier is specified.
100- :fx This is an *f32 * or *f16 * operand depending on
104+ :fx This is a *f32 * or *f16 * operand, depending on
101105 :ref: `m_op_sel_hi<amdgpu_synid_mad_mix_op_sel_hi> ` modifier.
102- :<type> Operand *type * differs from *type *
106+ :<type> The operand *type * differs from the *type *
103107 :ref: `implied by the opcode name<amdgpu_syn_instruction_type> `.
104- This tag specifies actual operand *type *.
108+ This tag specifies the actual operand *type *.
105109 ============== =================================================================================
106110
107111Examples:
@@ -119,7 +123,8 @@ Modifiers
119123
120124An instruction may have zero or more optional *modifiers *. They are space-separated in the description:
121125
122- ``< ``\ :ref: `description of modifier 0<amdgpu_syn_instruction_modifier_notation> `\ ``> < ``\ :ref: `description of modifier 1<amdgpu_syn_instruction_modifier_notation> `\ ``> ... ``
126+ | ``<``\ :ref:`description of modifier 0<amdgpu_syn_instruction_modifier_notation>`\ ``>
127+ <``\ :ref:`description of modifier 1<amdgpu_syn_instruction_modifier_notation>`\ ``> ...``
123128
124129The order of *modifiers * is fixed.
125130
@@ -132,4 +137,4 @@ A *modifier* is described using the following notation:
132137
133138 *<name> *
134139
135- Where *name * is a link to a description of the *modifier *.
140+ Where the *name * is a link to a description of the *modifier *.
0 commit comments