From: Luke Kenneth Casson Leighton Date: Mon, 7 Oct 2019 15:27:50 +0000 (+0100) Subject: add SHAPE / REMAP area to VBLOCK2 X-Git-Tag: convert-csv-opcode-to-binary~3874 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5447a27b35bea28c036361ea8c1234ea0eca075e;p=libreriscv.git add SHAPE / REMAP area to VBLOCK2 --- diff --git a/simple_v_extension/vblock_format.mdwn b/simple_v_extension/vblock_format.mdwn index 680d747bd..6cad577b9 100644 --- a/simple_v_extension/vblock_format.mdwn +++ b/simple_v_extension/vblock_format.mdwn @@ -153,6 +153,28 @@ The swizzle table format is included here for convenience: Swizzle blocks are only accessible using the "VBLOCK2" format. +# REMAP Area Format + +The REMAP area is divided into two areas: + +* Register-to-SHAPE. This defines which registers have which shapes. + Each entry is 8-bits in length. +* SHAPE Table entries. These are 32-bits in length and are aligned + to (start on) a 16 bit boundary. + +REMAP Table Entries: + +| 7:5 | 4:0 | +| -------- | ------ | +| shapeidx | regnum | + +When both shapeidx and regnum are zero, this indicates the end of the +REMAP Register-to-SHAPE section. The REMAP Table section size is then +aligned to a 16-bit boundary. 32-bit SHAPE Table Entries then fill the +remainder of the REMAP area, and are indexed in order by shapeidx. + +In this way, multiple registers may share the same "shape" characteristics. + # SHAPE Table Format The shape table format is included here for convenience: diff --git a/simple_v_extension/vblock_format_table.mdwn b/simple_v_extension/vblock_format_table.mdwn index 2c274a727..b3b6a6586 100644 --- a/simple_v_extension/vblock_format_table.mdwn +++ b/simple_v_extension/vblock_format_table.mdwn @@ -36,12 +36,26 @@ RISC-V ISA format. Note that the length is 96+16\*nnnnn, not 192+ VBLOCK2 extends the VBLOCK fields: -| 15:12 | 11:10 | 9:8 | 7:5 | 4:0 | -| ----- | ----- | ---- | --- | ---- | -| rsvd | rplen2 | pplen2 | swlen | ilen | +| 15 | 14:12 | 11:10 | 9:8 | 7:5 | 4:0 | +| ---- | ----- | ----- | ---- | --- | ---- | +| rsvd | mapsz | rplen2 | pplen2 | swlen | ilen | * ilen is the instruction length (number of 16-bit blocks) * swlen specifies the number of "swizzle" blocks * rplen2 extends rplen by 2 bits * pplen2 extends pplen by 2 bits -* 4 bits are reserved for additional tables (Matrices?) +* mapsz indicates the size of the "remap" area. See table below for size +* 1 bit is reserved for extensions + +Mapsz to Remap size is in number of 16-bit blocks: + +| mapsz | remap size | +| ----- | ---------- | +| 0 | 0 | +| 1 | 6 | +| 2 | 7 | +| 3 | 8 | +| 4 | 10 | +| 5 | 12 | +| 6 | 14 | +| 7 | 16 |