s_buffer_atomic_xor GPU Native ISA AMD Scalar
Scalar Memory
Calculate bitwise XOR given two unsigned 32-bit integer values stored in the data register and a location in a scalar buffer surface.
Encoding
The ENC_SMEM layout from AMD's machine-readable ISA specification (AMD CDNA 4). Opcode 74 in OP rebuilds 0x00000000C1280000, an identifier AMD lists for this encoding. Bits marked unassigned have no field in the specification. The same in the other 3 generations that define it.
Operands
-
SDATA
Written. N/A Data format: Value can be anything. (OPR_SREG, FMT_ANY) -
SBASE
Read. N/A Data format: 128-bit buffer resource constant. (OPR_SREG, FMT_RSRC_SCALAR) -
SOFFSET
Read. N/A Data format: N/A (OPR_SMEM_OFFSET, FMT_NUM_B32)
In AMD's order, as its machine-readable ISA specification lists them for the ENC_SMEM encoding (AMD CDNA 4).
GFX Target Compatibility
Per-target GFX compatibility has not yet been verified for this instruction.
Related
More in Scalar Memory
Reference
Example
s_buffer_atomic_xor s5, s[4:7], s2A real instruction accepted by the LLVM assembler, taken verbatim from LLVM's own AMDGPU MC test suite (gfx10_asm_smem.s). Not from an AMD document, and not authored here.
Sources
- AMD Machine-Readable GPU ISA Specification ↗ - Advanced Micro Devices, Inc.
- LLVM MC assembler tests for AMDGPU ↗ - LLVM Project