Excalibur electronic A-MNL-NIOSPROG-01.1 用户手册

下载
页码 122
96
Altera Corporation
32-Bit Instruction Set
STS
Store 32-bit Data To Memory (Stack Addressing Mode)
Operation:
Mem32[align32(%sp + (IMM8
× 4))] ← RA
Assembler Syntax:
STS [%sp,IMM8],%rA
Example:
STS [%sp,17],%i5 ; store %i5 at stack + 68
                 ; first register can only be %sp
Description:
Stores the 32-bit value in RA to memory. Data is always written to a word-aligned 
address given by bits 31..2 of %sp  (the two LSBs of %sp are ignored) plus an 8-
bit, unsigned, word-scaled offset given by IMM8.
Conventionally, software uses %o6 (aka %sp) as a stack-pointer. STS allows 
single-instruction access to any data word at a known offset in a 1Kbyte range 
above %sp.
Condition Codes:
Flags: Unaffected
Instruction Format:
Ri8
Instruction Fields:
A = Register index for operand RA
IMM8 = 8-bit immediate value
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
1 1
0
IMM8
A
N
V
Z
C