GPU/Shader Instruction Set: Difference between revisions

Smea (talk | contribs)
Smea (talk | contribs)
No edit summary
Line 38: Line 38:


Format 2 : (used for flow control instructions)
Format 2 : (used for flow control instructions)
{| class="wikitable" border="1"
|-
!  Offset
!  Size
!  Description
|-
|  0x0
|  0x8
|  Number of instructions (NUM)
|-
|  0xA
|  0xC
|  Destination offset (in words) (DST)
|-
|  0x1A
|  0x6
|  Opcode
|}
Format 3 : (used for conditional flow control instructions)
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
Line 48: Line 68:
|  Number of instructions ? (NUM)
|  Number of instructions ? (NUM)
|-
|-
0x8
0xA
0x10?
0xC
|  Destination offset (DST)
|  Destination offset (in words) (DST)
|-
|  0x16
|  0x4
|  Uniform boolean ID (BOOL)
|-
|-
|  0x1A
|  0x1A
Line 105: Line 129:
|  CALL
|  CALL
|  Jumps to DST and executes NUM instructions
|  Jumps to DST and executes NUM instructions
|-
|  0x26
|  2
|  CALLC
|  Jumps to DST and executes NUM instructions on the condition that BOOL is true
|-
|  0x27
|  2
|  IFU
|  Jumps to DST and executes NUM instructions (?) on the condition that BOOL is true
|-
|-
|  0x21
|  0x21