Copyright | (c) David Cox 2024 |
---|---|
License | BSD-3-Clause |
Maintainer | standardsemiconductor@gmail.com |
Safe Haskell | None |
Language | Haskell2010 |
Lion.Rvfi
Description
As the pipeline processes instructions, it populates the fields of the Rvfi data. When the instruction reaches the end of the pipeline, the core retires the instruction and writes the Rvfi data to output. This output is inspected and verified by the riscv-formal framework. See riscv-formal for more information about the interface. To verify the Lion core, see lion-formal.
Synopsis
- data RvfiCsr (n :: Nat) = RvfiCsr {}
- rdataCsr :: forall (n :: Nat) f. Functor f => (("rdata" ::: BitVector n) -> f ("rdata" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n)
- rmaskCsr :: forall (n :: Nat) f. Functor f => (("rmask" ::: BitVector n) -> f ("rmask" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n)
- wdataCsr :: forall (n :: Nat) f. Functor f => (("wdata" ::: BitVector n) -> f ("wdata" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n)
- wmaskCsr :: forall (n :: Nat) f. Functor f => (("wmask" ::: BitVector n) -> f ("wmask" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n)
- data Rvfi = Rvfi {
- _rvfiValid :: "valid" ::: Bool
- _rvfiOrder :: "order" ::: BitVector 64
- _rvfiInsn :: "insn" ::: BitVector 32
- _rvfiTrap :: "trap" ::: Bool
- _rvfiHalt :: "halt" ::: Bool
- _rvfiIntr :: "intr" ::: Bool
- _rvfiMode :: "mode" ::: BitVector 2
- _rvfiIxl :: "ixl" ::: BitVector 2
- _rvfiRs1Addr :: "rs1_addr" ::: Unsigned 5
- _rvfiRs2Addr :: "rs2_addr" ::: Unsigned 5
- _rvfiRs1Data :: "rs1_rdata" ::: BitVector 32
- _rvfiRs2Data :: "rs2_rdata" ::: BitVector 32
- _rvfiRdAddr :: "rd_addr" ::: Unsigned 5
- _rvfiRdWData :: "rd_wdata" ::: BitVector 32
- _rvfiPcRData :: "pc_rdata" ::: BitVector 32
- _rvfiPcWData :: "pc_wdata" ::: BitVector 32
- _rvfiMemAddr :: "mem_addr" ::: BitVector 32
- _rvfiMemRMask :: "mem_rmask" ::: BitVector 4
- _rvfiMemWMask :: "mem_wmask" ::: BitVector 4
- _rvfiMemRData :: "mem_rdata" ::: BitVector 32
- _rvfiMemWData :: "mem_wdata" ::: BitVector 32
- _rvfiCsrMinstret :: "csr_minstret" ::: RvfiCsr 64
- _rvfiCsrMcycle :: "csr_mcycle" ::: RvfiCsr 64
- _rvfiCsrMscratch :: "csr_mscratch" ::: RvfiCsr 32
- _rvfiCsrMstatus :: "csr_mstatus" ::: RvfiCsr 32
- _rvfiCsrMisa :: "csr_misa" ::: RvfiCsr 32
- rvfiCsrMcycle :: Lens' Rvfi ("csr_mcycle" ::: RvfiCsr 64)
- rvfiCsrMinstret :: Lens' Rvfi ("csr_minstret" ::: RvfiCsr 64)
- rvfiCsrMisa :: Lens' Rvfi ("csr_misa" ::: RvfiCsr 32)
- rvfiCsrMscratch :: Lens' Rvfi ("csr_mscratch" ::: RvfiCsr 32)
- rvfiCsrMstatus :: Lens' Rvfi ("csr_mstatus" ::: RvfiCsr 32)
- rvfiHalt :: Lens' Rvfi ("halt" ::: Bool)
- rvfiInsn :: Lens' Rvfi ("insn" ::: BitVector 32)
- rvfiIntr :: Lens' Rvfi ("intr" ::: Bool)
- rvfiIxl :: Lens' Rvfi ("ixl" ::: BitVector 2)
- rvfiMemAddr :: Lens' Rvfi ("mem_addr" ::: BitVector 32)
- rvfiMemRData :: Lens' Rvfi ("mem_rdata" ::: BitVector 32)
- rvfiMemRMask :: Lens' Rvfi ("mem_rmask" ::: BitVector 4)
- rvfiMemWData :: Lens' Rvfi ("mem_wdata" ::: BitVector 32)
- rvfiMemWMask :: Lens' Rvfi ("mem_wmask" ::: BitVector 4)
- rvfiMode :: Lens' Rvfi ("mode" ::: BitVector 2)
- rvfiOrder :: Lens' Rvfi ("order" ::: BitVector 64)
- rvfiPcRData :: Lens' Rvfi ("pc_rdata" ::: BitVector 32)
- rvfiPcWData :: Lens' Rvfi ("pc_wdata" ::: BitVector 32)
- rvfiRdAddr :: Lens' Rvfi ("rd_addr" ::: Unsigned 5)
- rvfiRdWData :: Lens' Rvfi ("rd_wdata" ::: BitVector 32)
- rvfiRs1Addr :: Lens' Rvfi ("rs1_addr" ::: Unsigned 5)
- rvfiRs1Data :: Lens' Rvfi ("rs1_rdata" ::: BitVector 32)
- rvfiRs2Addr :: Lens' Rvfi ("rs2_addr" ::: Unsigned 5)
- rvfiRs2Data :: Lens' Rvfi ("rs2_rdata" ::: BitVector 32)
- rvfiTrap :: Lens' Rvfi ("trap" ::: Bool)
- rvfiValid :: Lens' Rvfi ("valid" ::: Bool)
- fromRvfi :: First Rvfi -> Rvfi
- mkRvfi :: Rvfi
Documentation
data RvfiCsr (n :: Nat) Source #
RISC-V Formal Csr Interface
Constructors
RvfiCsr | |
Instances
rdataCsr :: forall (n :: Nat) f. Functor f => (("rdata" ::: BitVector n) -> f ("rdata" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n) Source #
rmaskCsr :: forall (n :: Nat) f. Functor f => (("rmask" ::: BitVector n) -> f ("rmask" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n) Source #
wdataCsr :: forall (n :: Nat) f. Functor f => (("wdata" ::: BitVector n) -> f ("wdata" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n) Source #
wmaskCsr :: forall (n :: Nat) f. Functor f => (("wmask" ::: BitVector n) -> f ("wmask" ::: BitVector n)) -> RvfiCsr n -> f (RvfiCsr n) Source #
RISC-V Formal Interface
Constructors
Rvfi | |
Fields
|
Instances
Generic Rvfi Source # | |||||
Defined in Lion.Rvfi Associated Types
| |||||
Show Rvfi Source # | |||||
NFDataX Rvfi Source # | |||||
Eq Rvfi Source # | |||||
type Rep Rvfi Source # | |||||
Defined in Lion.Rvfi type Rep Rvfi = D1 ('MetaData "Rvfi" "Lion.Rvfi" "lion-0.4.0.1-inplace" 'False) (C1 ('MetaCons "Rvfi" 'PrefixI 'True) ((((S1 ('MetaSel ('Just "_rvfiValid") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("valid" ::: Bool)) :*: (S1 ('MetaSel ('Just "_rvfiOrder") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("order" ::: BitVector 64)) :*: S1 ('MetaSel ('Just "_rvfiInsn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("insn" ::: BitVector 32)))) :*: (S1 ('MetaSel ('Just "_rvfiTrap") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("trap" ::: Bool)) :*: (S1 ('MetaSel ('Just "_rvfiHalt") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("halt" ::: Bool)) :*: S1 ('MetaSel ('Just "_rvfiIntr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("intr" ::: Bool))))) :*: ((S1 ('MetaSel ('Just "_rvfiMode") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mode" ::: BitVector 2)) :*: (S1 ('MetaSel ('Just "_rvfiIxl") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("ixl" ::: BitVector 2)) :*: S1 ('MetaSel ('Just "_rvfiRs1Addr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rs1_addr" ::: Unsigned 5)))) :*: ((S1 ('MetaSel ('Just "_rvfiRs2Addr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rs2_addr" ::: Unsigned 5)) :*: S1 ('MetaSel ('Just "_rvfiRs1Data") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rs1_rdata" ::: BitVector 32))) :*: (S1 ('MetaSel ('Just "_rvfiRs2Data") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rs2_rdata" ::: BitVector 32)) :*: S1 ('MetaSel ('Just "_rvfiRdAddr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rd_addr" ::: Unsigned 5)))))) :*: (((S1 ('MetaSel ('Just "_rvfiRdWData") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("rd_wdata" ::: BitVector 32)) :*: (S1 ('MetaSel ('Just "_rvfiPcRData") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("pc_rdata" ::: BitVector 32)) :*: S1 ('MetaSel ('Just "_rvfiPcWData") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("pc_wdata" ::: BitVector 32)))) :*: (S1 ('MetaSel ('Just "_rvfiMemAddr") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mem_addr" ::: BitVector 32)) :*: (S1 ('MetaSel ('Just "_rvfiMemRMask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mem_rmask" ::: BitVector 4)) :*: S1 ('MetaSel ('Just "_rvfiMemWMask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mem_wmask" ::: BitVector 4))))) :*: ((S1 ('MetaSel ('Just "_rvfiMemRData") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mem_rdata" ::: BitVector 32)) :*: (S1 ('MetaSel ('Just "_rvfiMemWData") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("mem_wdata" ::: BitVector 32)) :*: S1 ('MetaSel ('Just "_rvfiCsrMinstret") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("csr_minstret" ::: RvfiCsr 64)))) :*: ((S1 ('MetaSel ('Just "_rvfiCsrMcycle") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("csr_mcycle" ::: RvfiCsr 64)) :*: S1 ('MetaSel ('Just "_rvfiCsrMscratch") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("csr_mscratch" ::: RvfiCsr 32))) :*: (S1 ('MetaSel ('Just "_rvfiCsrMstatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("csr_mstatus" ::: RvfiCsr 32)) :*: S1 ('MetaSel ('Just "_rvfiCsrMisa") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ("csr_misa" ::: RvfiCsr 32)))))))) |