Skip to content

Regs/Transpose: Add compute parameter register to register frontend and fix transpose to/from misaligned addresses - #160

Open
da-gazzi wants to merge 6 commits into
pulp-platform:develfrom
mosaic-soc:pr/reg-transpose
Open

Regs/Transpose: Add compute parameter register to register frontend and fix transpose to/from misaligned addresses#160
da-gazzi wants to merge 6 commits into
pulp-platform:develfrom
mosaic-soc:pr/reg-transpose

Conversation

@da-gazzi

@da-gazzi da-gazzi commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Merge order:

This PR is based on the PR making the compute engine instantiation an elaboration-time parameter instead of a generation-time one, see #159 - that PR should be merged before this one.

Changes:

  • Add CI input for additional register frontends to generate in the deploy job (IDMA_ADD_FE_IDS)
  • Add a register to hold compute (i.e., transpose) configuration to the register file definition
  • BUGFIX: Transpose was buggy when the destination buffer was misaligned to the data bus
    • Previously, an output was popped from the transposition unit on every accepted output beat. As a misaligned write is split into 2 beats, that led to some data being dropped and AW transfers being issued without a corresponding W transfer to follow them up
    • This has been fixed by connecting the transpose unit's ready_i to w_dp_req_ready instead of write_beat_done; that signal is asserted on the last transaction of a write transfer, which is the correct behavior.

georg and others added 6 commits July 13, 2026 09:54
- This target generates C headers in `target/sw` with both the `raw-header` and `c-header` PeakRDL plugins
- Also added to `deploy` CI job
- the PeakRDL `c-header` plugin generates structs with `__attribute__((__packed__))` which ensures proper packing of fields but can also cause the compiler to emit byte loads/stores to access 32-bit registers, which is definitely not what we want. The `unpacked` version of the C header has the attribute removed.
- The `idma_sw_clean` target had a typo and didn't actually clean anything, this is fixed now.
- Replace `enable_compute` in backend generation with a SystemVerilog parameter
- Add `EnableCompute`, `ComputeOps`, and `ComputeFullDuplex` parameters to
  eligible backend, synthesis wrapper, and transport-layer modules.
- Omit compute parameters entirely for generated topologies that cannot support
  the compute datapath
- Keep the non-compute path available in compute-capable variants with
  `EnableCompute = 0`, and instantiate `idma_otf_compute` only when enabled.
- Remove `IDMA_VIDMA_IDS` / `--compute-ids` plumbing from the generator and
  makefile; compute support is now selected at elaboration.
- Update transpose testbenches to enable compute explicitly and keep the inst64
  frontend backend instantiation compute-disabled
- `compute_cfg` register is added after existing registers
- Controls `enable`, `op`, `mode`, `tensor_m` and `tensor_n`
- Connected to the relevant fields of the ND request struct in the register top-level template
- Add required additional frontend IDs to CI deploy job
- With misaligned destination addresses, 2 write beats may be required to write a single row of the transpose buffer.
- The `ready_i` signal should thus be asserted only when the entire transaction is done (`w_dp_req_ready` asserted), not when a single write beat is done.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant