UNPACR_NOP_SETDVALID
tenstorrent_tt_isa)Tenstorrent Wormhole B0 & Blackhole A0
main
userTensix, Unpackers, WormholeB0Summary
Similar to a SETDVALID instruction, but sequenced after previous instructions to the same unpacker.
Syntax / Encoding
TT_UNPACR_NOP(/* u1 */ WhichUnpacker, 0x7)
Binary Encodings (1)
| Width | Format | Bit Pattern | Mask / Match |
|---|---|---|---|
| 32 | Tensix-32b | 01000011xxxxxxxxxxxxxxxxxxxxx111 | 0xff000007 / 0x43000007 |
Operands
| Name | Description |
|---|---|
WhichUnpacker |
Reference Notes
# `UNPACR_NOP` (Give `SrcA` or `SrcB` banks to Matrix Unit, sequenced with UNPACR)
**Summary:** Similar to a [`SETDVALID`](SETDVALID.md) instruction, but sequenced after previous instructions to the same unpacker.
**Backend execution unit:** [Unpackers](Unpackers/README.md)
## Syntax
```c
TT_UNPACR_NOP(/* u1 */ WhichUnpacker, 0x7)
```
## Encoding

## Functional model
```c
uint1_t StateID = ThreadConfig[CurrentThread].CFG_STATE_ID_StateID;
auto& ConfigState = Config[StateID];
if (WhichUnpacker == 0) {
if (Unpackers[0].WroteDst) {
UndefinedBehavior(); // Hardware bug; see Unpackers[0].WroteDst in SrcASrcB.md
}
SrcA[Unpackers[0].SrcBank].AllowedClient = SrcClient::MatrixUnit;
if (TTArchitecture == Blackhole) {
ImpliedSrcAFmt[Unpackers[0].SrcBank] = ConfigState.THCON_SEC[0].REG2_Out_data_format;
}
Unpackers[0].SrcBank ^= 1;
uint2_t T = TTArchitecture == Wormhole ? Unpackers[0].WriteThread : CurrentThread; // See SrcASrcB.md
Unpackers[0].SrcRow[T] = ThreadConfig[T].SRCA_SET_Base << 4;
} else {
SrcB[Unpackers[1].SrcBank].AllowedClient = SrcClient::MatrixUnit;
if (TTArchitecture == Blackhole) {
ImpliedSrcBFmt[Unpackers[1].SrcBank] = ConfigState.THCON_SEC[1].REG2_Out_data_format;
}
Unpackers[1].SrcBank ^= 1;
uint2_t T = TTArchitecture == Wormhole ? Unpackers[1].WriteThread : CurrentThread; // See SrcASrcB.md
Unpackers[1].SrcRow[T] = ThreadConfig[T].SRCB_SET_Base << 4;
}
```
## Instruction scheduling
This instruction does not automatically wait at the Wait Gate to ensure that `AllowedClient == SrcClient::Unpackers`, so unless sequenced after an [`UNPACR` (Move datums from L1 to `SrcA` or `SrcB` or `Dst`)](UNPACR_Regular.md) or [`UNPACR_NOP` (Set `SrcA` or `SrcB` to zero, sequenced with UNPACR)](UNPACR_NOP_ZEROSRC.md) instruction which performs the desired wait, software may wish to use [`STALLWAIT`](STALLWAIT.md) (with block bit B3 and condition code C10 or C11) prior to `UNPACR_NOP`.