Skip to content

Feedback on the accelerator interface #3

@Silabs-ArjanB

Description

@Silabs-ArjanB

Hi Noam,

Thank you very much for writing up the proposal for the accelerator interface.

I have some questions and suggestion that you maybe can take into account:

  • ready/valid protocol
The initiator asserts valid. The assertion of valid must not depend on ready.
Once valid has been asserted all data must remain stable.
The receiver asserts ready whenever it is ready to receive the transaction.
When both valid and ready are high the transaction is successful.

Can you make it explicit that a default ready is allowed (i.e. ready = 1 while valid = 0) and that ready can be retracted at any time. You state that the handshake is according to the AMBA standard. I assume you are referring to AXI here. In AXI it is not allowed for outputs to combinatorially depend on inputs. In this case I would expect that we would actually allow ready to combinatorially depend on valid; if you agree can you please remove the 'AMBA standard' bit and state the allowed dependency explicitly?

  • Request channel (q)

I don't have an alternative naming proposal yet, but calling the request channel 'q channel' is going to lead to a lot of confusion as that is an ARM standard.

  • q_data_op

Can you state that whether q_data_op is a 32-bit instruction or a 16-bit instruction will be based on the existing RISC-V definition, so q_data_op[1:0] specify whether the instruction is 16-bit or not and q_data_op[6:2] further differentiate the instruction width as specified in the RISC-V unprivileged spec. (You might want to add an InstrWidth parameter as well.)

Please also prescribe that instructions which are shorter than the width of q_data_op will always be present in the LSBs and that the MSBs should be ignored in that case. For example for 'compressed instructions' are always present in q_data_op[15:0] and if q-data_op[1:0] != 2'b11, then q_data_op[31:16] shall be ignored (it might not contain bits related to the next instruction).

  • Match indicator

The request channel needs to have a 'match' signal flowing from request channel target to request channel initiator (with validity signaled with 'ready'). The signal will indicate whether a connected accelerator can/will handle the provided q_data_op. (If no match is received by the RISC-V and also the RISC-V itself cannot decode the instruction, then it will be classified as an illegal instruction). I think that we should explicitly allow that 'match' combinatorially can depend on q_data_op/valid.

  • A/B/C operand

As discussed there is a need for the RISC-V core to know which operands are actually required for a specific accelerated instruction. The accelerator shall signal this via 3 sepearate signals with same validity/timing as above 'match' signal. I think that we should explicitly allow that these 3 signals combinatorially can depend on q_data_op/valid.

  • Operand destination

Just like you defined the 'operand origin', can you please add a section on 'operand destination' (and this needs to be defined for both compressed and uncompressed instructions). On top of the obvious choice of q_data_op[11:7] as the destination for 32-bit instructions, we would like to see the ability for dual-register writeback, similar to how this is done in the P extension (e.g. for even destination registers other than x0, a dual write back can be performed to Xn and Xn+1). The accelerator can signal its need for a dual writeback by another signal flowing from request channel target to request channel initiator (with validity signaled with 'ready').

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions