Assembly:

SHXS rd, rs(rt)

nanoMIPS, not available in NMS

Store Half

Purpose:

Store HalfindeXed Scaled.Store halfword from register $rt to memory address $rt +

2*$rs (register plus scaled register).

Availability:

nanoMIPS, not available in NMS

Format:

001000

rt

rs

rd

0101

1

000

111

6

5

5

5

4

1

3

3

Operation:

if C0.Config5.NMS == 1:
    raise exception('RI')
va = effective_address(GPR[rs]<<1, GPR[rt], 'Store')
data = zero_extend(GPR[rd], from_nbits=16)
write_memory_at_va(data, va, nbytes=2)

Exceptions:

Address Error. Bus Error. Reserved Instruction on NMS Cores. TLB Invalid. TLB Modified. TLB Refill. Watch.