Overview
Flute is a RISC-V processor implementation in the CTSRD-CHERI ecosystem. The TestRIG paper identifies Flute as a 5-stage in-order pipeline processor implementing RV64 and lists its public repository as https://github.com/CTSRD-CHERI/Flute.[1]
Role in TestRIG and RVFI-DII
In the TestRIG ecosystem, implementations are instrumented with RVFI-DII: Direct Instruction Injection (DII) supplies instruction input, while RVFI supplies trace output for interactive verification.[2]
Flute is discussed as one of the implementations used with TestRIG-style RVFI-DII instrumentation. The paper notes that the simple single-issue design of Piccolo and Flute made it possible to replace the instruction cache entirely with a DII queue delivering one instruction per cycle, either compressed or uncompressed.[3]
The paper also describes a synchronization issue for DII when instructions are canceled or dropped in the pipeline: RVFI-DII requires one RVFI trace entry for each DII instruction injected. While adding RVFI-DII to Flute, the authors developed a design that attaches a sequence ID to each RVFI instruction, carries it with the PC through the pipeline, and has Instruction Fetch actively request each instruction ID from the DII sequence so redirects work naturally.[4]
Implementation notes
- Architecture class: RV64 processor implementation.[1]
- Pipeline style: 5-stage in-order pipeline.[1]
- Test instrumentation: RVFI-DII support was added to Flute; a more capable DII unit was later backported to Flute.[4]
- DII strategy noted for Flute: because Flute is simple and single-issue, the instruction cache could be replaced with a DII queue delivering one instruction every cycle.[3]
[1]: Evidence chunk 29a08eb7-9b16-4f86-a71a-b495865d9f58.
[2]: Evidence chunk fd70f40f-b468-4b11-b81a-2bb51b51a113.
[3]: Evidence chunks 29a08eb7-9b16-4f86-a71a-b495865d9f58, fd70f40f-b468-4b11-b81a-2bb51b51a113.
[4]: Evidence chunk fd70f40f-b468-4b11-b81a-2bb51b51a113.