Encoding:

MSA

011110

s10

rs

wd

MI10

1001

df

6

10

5

5

4

2

Format:

ST.df 

Vector Store

ST.B wd,s10(rs)

MSA

Vector Store

ST.H wd,s10(rs)

MSA

Vector Store

ST.W wd,s10(rs)

MSA

Vector Store

ST.D wd,s10(rs)

MSA

Vector Store

Purpose:

Vector Store

Vector store element-by-element to base register plus offset memory address.

Description:

memory[rs + s10 + i * sizeof(wd[i])] = wd[i]

The WRLEN / 8 bytes in vector wd are stored as elements of data format df at the effective memory location addressed by the base rs and the 10-bit signed immediate offset s10.

The s10 offset in data format df units is added to the base rs to form the effective memory location address. rs and the effective memory location address have no alignment restrictions.

If the effective memory location address is element aligned, the vector store instruction is atomic at the element level with no guaranteed ordering among elemen ts, i.e. each element store is an atomic operation issued in no particular order with respect to the element's vector position.

By convention, in the assembly language syntax all offsets are in bytes and have to be multiple of the size of the data format df. The assembler determines the s10 bitfield value dividing the byte offset by the size of the data format df.

Restrictions:

Address-dependent exceptions are possible.

Operation:

ST.B
   a = rs + s10
   StoreByteVector(WR[wd]WRLEN-1..0, a, WRLEN/8)
ST.H
   a = rs + s10 * 2
   StoreHalfwordVector(WR[wd]WRLEN-1..0, a, WRLEN/16)
ST.W
   a = rs + s10 * 4
   StoreWordVector(WR[wd]WRLEN-1..0, a, WRLEN/32)
ST.D
   a = rs + s10 * 8
   StoreDoublewordVector(WR[wd]WRLEN-1..0, a, WRLEN/64)
function StoreByteVector(tt, a, n)
   /* Implementation defined store n byte vector tt to virtual
         address a. */
endfunction StoreByteVector
function StoreHalfwordVector(tt, a, n)
   /* Implementation defined store n halfword vector tt to virtual
          address a. */
endfunction StoreHalfwordVector
function StoreWordVector(tt, a, n)
   /* Implementation defined store n word vector tt to virtual
         address a. */
endfunction StoreWordVector
function StoreDoublewordVector(tt, a, n)
   /* Implementation defined store n doubleword vector tt to virtual
         address a. */
endfunction StoreDoublewordVector

Exceptions:

Reserved Instruction Exception, MSA Disabled Exception. Data access TLB and Address Error Exceptions.