How sequencer/rocket works
Rocket is a RISC-V processor core being refactored from rocket-chip into a more independent Chisel project; this tree is the diplomatic integration side. Its main runtime path is instruction fetch, buffering and decode, execution and control, then memory access and retirement, hosted in a tile that connects the core to caches, translation, interrupts, and optional coprocessors. The README also describes planned decoupled bus interfaces and online cosimulation, but those implementations are not established by the sampled sources. Edges below are limited to explicit excerpts or SOURCE INDEX references.
Main entry points: RocketCore.scala Rocket core · RocketTile.scala Rocket tile · Frontend.scala Frontend · IDecode.scala Instruction decode
Components 25
Tile Integration
- Rocket tile
diplomatic/src/tile/RocketTile.scala - TileLink fabric
diplomatic/src/tile/BaseTile.scala - Interrupt handling
diplomatic/src/tile/Interrupts.scala - Bus error unit
diplomatic/src/tile/BusErrorUnit.scala - Scratchpad port
diplomatic/src/rocket/ScratchpadSlavePort.scala
Core Pipeline
- Rocket core
diplomatic/src/rocket/RocketCore.scala - Frontend
diplomatic/src/rocket/Frontend.scala - Instruction buffer
diplomatic/src/rocket/IBuf.scala - Instruction decode
diplomatic/src/rocket/IDecode.scala - Instruction encodings
diplomatic/src/rocket/Instructions.scala - 32-bit encodings
diplomatic/src/rocket/Instructions32.scala - CSR and traps
diplomatic/src/rocket/CSR.scala - Custom CSRs
diplomatic/src/tile/CustomCSRs.scala
Memory System
- Instruction cache
diplomatic/src/rocket/ICache.scala - Data cache
diplomatic/src/rocket/DCache.scala - Cache interface
diplomatic/src/rocket/HellaCache.scala - Address translation
diplomatic/src/rocket/TLB.scala - Page-table walker
diplomatic/src/rocket/PTW.scala
Execution Units
- Floating point
diplomatic/src/tile/FPU.scala - Multiply and divide
diplomatic/src/rocket/Multiplier.scala - RoCC coprocessors
diplomatic/src/tile/LazyRoCC.scala
Simulation Interface
- Verilator emulator
diplomatic/resources/csrc/emulator.cc - Remote bitbang
diplomatic/resources/csrc/remote_bitbang.cc
Other components
- RISC-V program
- OpenOCD / GDB
Connections 26
- RISC-V program → Frontend: fetch instructions
- Frontend → Instruction cache: requests fetches
diplomatic/src/rocket/Frontend.scala - Frontend → Instruction buffer: feeds instructions
- Rocket core → Instruction buffer: consumes buffered instructions
diplomatic/src/rocket/RocketCore.scala - Rocket core → Instruction decode: decodes instructions
diplomatic/src/rocket/RocketCore.scala - Instruction decode → Instruction encodings: matches encodings
diplomatic/src/rocket/IDecode.scala - Instruction decode → 32-bit encodings: uses encodings
diplomatic/src/rocket/IDecode.scala - Rocket core → CSR and traps: controls privilege state
- CSR and traps → Custom CSRs: uses custom CSR definitions
diplomatic/src/rocket/CSR.scala - Rocket core → Multiply and divide: issues arithmetic requests
diplomatic/src/rocket/RocketCore.scala - Rocket core → Floating point: connects floating point
- Rocket core → RoCC coprocessors: routes coprocessor commands
- Rocket core → Frontend: connects fetch interface
- Rocket core → Data cache: sends data requests
- Rocket core → Page-table walker: connects translation walk
- Data cache → Cache interface: uses cache interface
diplomatic/src/rocket/DCache.scala - Instruction cache → Address translation: translates fetch addresses
- Data cache → Address translation: translates data addresses
- Page-table walker → Address translation: services page walks
- Rocket tile → Rocket core: instantiates core
diplomatic/src/tile/RocketTile.scala - Rocket tile → TileLink fabric: extends tile fabric
diplomatic/src/tile/BaseTile.scala - Rocket tile → Scratchpad port: connects scratchpad
diplomatic/src/tile/RocketTile.scala - Rocket tile → Bus error unit: reports cache errors
diplomatic/src/tile/RocketTile.scala - Rocket tile → Interrupt handling: integrates interrupts
- Verilator emulator → Remote bitbang: creates debug server
diplomatic/resources/csrc/emulator.cc - OpenOCD / GDB → Remote bitbang: drives JTAG remotely