Open as PDF
STB Store Byte to Memory With a 15-Bit Unsigned Constant Offset
3-238 Instruction Set SPRU733
Store Byte to Memory With a 15-Bit Unsigned Constant Offset
Syntax STB (.unit) src, *+B14/B15[ucst15]
.unit = .D2
Compatibility C62x, C64x, C67x, and C67x+ CPU
31 29 28 27 23 22 876 43210
creg z src ucst15 y 0 1 1 1 1 s p
3 1 5 15 1 1 1
Description Stores a byte to memory from a general-purpose register (src). The memory
address is formed from a base address register B14 (y = 0) or B15 (y = 1) and
an offset, which is a 15-bit unsigned constant (ucst15). The assembler selects
this format only when the constant is larger than five bits in magnitude. This
instruction executes only on the .D2 unit.
The offset, ucst15, is scaled by a left-shift of 0 bits. After scaling, ucst15 is
added to baseR. The result of the calculation is the address that is sent to
memory. The addressing arithmetic is always performed in linear mode.
For STB, the 8 LSBs of the src register are stored. src can be in either register
file. The s bit determines which file src is read from: s = 0 indicates src is in the
A register file and s = 1 indicates src is in the B register file.
Square brackets, [ ], indicate that the ucst15 offset is left-shifted by 0.
Parentheses, ( ), can be used to set a nonscaled, constant offset. You must
type either brackets or parentheses around the specified offset, if you use the
optional offset parameter.
Execution if (cond) src
This instruction executes only on the B side (.D2).