• Stars
    star
    331
  • Rank 127,323 (Top 3 %)
  • Language SystemVerilog
  • License
    Other
  • Created almost 7 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Common SystemVerilog components

Build Status GitHub tag (latest SemVer) SHL-0.51 license

Common Cells Repository

Maintainer: Nils Wistoff [email protected]

This repository contains commonly used cells and headers for use in various projects.

Cell Contents

This repository currently contains the following cells, ordered by categories. Please note that cells with status deprecated are not to be used for new designs and only serve to provide compatibility with old code.

Clocks and Resets

Name Description Status Superseded By
clk_int_div Arbitrary integer clock divider with config interface and 50% output clock duty cycle active
clk_int_div_static A convenience wrapper around clk_int_div with static division factor. active
clk_div Clock divider with integer divisor deprecated clk_int_div
clock_divider Clock divider with configuration registers deprecated clk_int_div
clock_divider_counter Clock divider using a counter deprecated clk_int_div
rstgen Reset synchronizer active
rstgen_bypass Reset synchronizer with dedicated test reset bypass active

Clock Domains and Asynchronous Crossings

Name Description Status Superseded By
cdc_4phase Clock domain crossing using 4-phase handshake, with ready/valid interface active
cdc_2phase Clock domain crossing using two-phase handshake, with ready/valid interface active
cdc_2phase_clearable Identical to cdc_2phase but supports one-sided async/sync resetting of either src or dst active
cdc_fifo_2phase Clock domain crossing FIFO using two-phase handshake, with ready/valid interface active
cdc_fifo_gray Clock domain crossing FIFO using a gray-counter, with ready/valid interface active
cdc_fifo_gray_clearable Identical to cdc_fifo_gray but supports one-sided async/sync resetting of either src or dst active
cdc_reset_ctrlr Lock-step reset sequencer accross clock domains (internally used by clearable CDCs) active
clk_mux_glitch_free A glitch-free clock multiplexer with parametrizeable number of inputs. active
edge_detect Rising/falling edge detector active
edge_propagator Propagates a single-cycle pulse across an asynchronous clock domain crossing active
edge_propagator_ack edge_propagator with sender-synchronous acknowledge pin (flags received pulse) active
edge_propagator_rx Receive slice of edge_propagator, requires only the receiver clock active
edge_propagator_tx Transmit slice of edge_propagator, requires only the sender clock active
isochronous_spill_register Isochronous clock domain crossing and full handshake (like spill_register) active
isochronous_4phase_handshake Isochronous four-phase handshake. active
pulp_sync Serial line synchronizer deprecated sync
pulp_sync_wedge Serial line synchronizer with edge detector deprecated sync_wedge
serial_deglitch Serial line deglitcher active
sync Serial line synchronizer active
sync_wedge Serial line synchronizer with edge detector active

Counters and Shift Registers

Name Description Status Superseded By
counter Generic up/down counter with overflow detection active
delta_counter Up/down counter with variable delta and overflow detection active
generic_LFSR_8bit 8-bit linear feedback shift register (LFSR) deprecated lfsr_8bit
lfsr_8bit 8-bit linear feedback shift register (LFSR) active
lfsr_16bit 16-bit linear feedback shift register (LFSR) active
lfsr 4...64-bit parametric Galois LFSR with optional whitening feature active
max_counter Up/down counter with variable delta that tracks its maximum value active
mv_filter ZARUBAF ADD DESCRIPTION active

Data Path Elements

Name Description Status Superseded By
addr_decode Address map decoder active
addr_decode_napot Address map decoder using naturally-aligned power of two (NAPOT) regions active
ecc_decode SECDED Decoder (Single Error Correction, Double Error Detection) active
ecc_encode SECDED Encoder (Single Error Correction, Double Error Detection) active
binary_to_gray Binary to gray code converter active
find_first_one Leading-one finder / leading-zero counter deprecated lzc
gray_to_binary Gray code to binary converter active
lzc Leading/trailing-zero counter active
onehot_to_bin One-hot to binary converter active
shift_reg Shift register for arbitrary types active
shift_reg_gated Shift register with ICG for arbitrary types active
rr_arb_tree Round-robin arbiter for req/gnt and vld/rdy interfaces with optional priority active
rrarbiter Round-robin arbiter for req/ack interface with look-ahead deprecated rr_arb_tree
prioarbiter Priority arbiter arbiter for req/ack interface with look-ahead deprecated rr_arb_tree
fall_through_register Fall-through register with ready/valid interface active
spill_register_flushable Register with ready/valid interface to cut all combinational interface paths and additional flush signal. active
spill_register Register with ready/valid interface to cut all combinational interface paths active
stream_arbiter Round-robin arbiter for ready/valid stream interface active
stream_arbiter_flushable Round-robin arbiter for ready/valid stream interface and flush functionality active
stream_demux Ready/valid interface demultiplexer active
lossy_valid_to_stream Convert Valid-only to ready/valid by updating in-flight transaction active
stream_join Ready/valid handshake join multiple to one common active
stream_mux Ready/valid interface multiplexer active
stream_register Register with ready/valid interface active
stream_fork Ready/valid fork active
stream_fork_dynamic Ready/valid fork, with selection mask for partial forking active
stream_filter Ready/valid filter active
stream_delay Randomize or delay ready/valid interface active
stream_to_mem Use memories without flow control for output data in streams. active
stream_xbar Fully connected crossbar with ready/valid interface. active
stream_omega_net One-way stream omega-net with ready/valid interface. Isomorphic to a butterfly. active
stream_throttle Restrict the number of outstanding transfers in a stream. active
sub_per_hash Substitution-permutation hash function active
popcount Combinatorial popcount (hamming weight) active
mem_to_banks Split memory access over multiple parallel banks active

Data Structures

Name Description Status Superseded By
cb_filter Counting-Bloom-Filter with combinational lookup active
fifo FIFO register with upper threshold deprecated fifo_v3
fifo_v2 FIFO register with upper and lower threshold deprecated fifo_v3
fifo_v3 FIFO register with generic fill counts active
stream_fifo FIFO register with ready/valid interface active
stream_fifo_optimal_wrap Wrapper that optimally selects either a spill register or a FIFO active
generic_fifo FIFO register without thresholds deprecated fifo_v3
generic_fifo_adv FIFO register without thresholds deprecated fifo_v3
sram SRAM behavioral model active
plru_tree Pseudo least recently used tree active
unread Empty module to sink unconnected outputs into active
read Dummy module that prevents a signal from being removed during synthesis active

Header Contents

This repository currently contains the following header files.

RTL Register Macros

The header file registers.svh contains macros that expand to descriptions of registers. To avoid misuse of always_ff blocks, only the following macros shall be used to describe sequential behavior. The use of linter rules that flag explicit uses of always_ff in source code is encouraged.

Macro Arguments Description
`FF q_sig, d_sig, rst_val, (clk_sig, arstn_sig) Flip-flop with asynchronous active-low reset
`FFAR q_sig, d_sig, rst_val, clk_sig, arst_sig Flip-flop with asynchronous active-high reset
`FFARN q_sig, d_sig, rst_val, clk_sig, arstn_sig deprecated Flip-flop with asynchronous active-low reset
`FFSR q_sig, d_sig, rst_val, clk_sig, rst_sig Flip-flop with synchronous active-high reset
`FFSRN q_sig, d_sig, rst_val, clk_sig, rstn_sig Flip-flop with synchronous active-low reset
`FFNR q_sig, d_sig, clk_sig Flip-flop without reset
`FFL q_sig, d_sig, load_ena, rst_val, (clk_sig, arstn_sig) Flip-flop with load-enable and asynchronous active-low reset
`FFLAR q_sig, d_sig, load_ena, rst_val, clk_sig, arst_sig Flip-flop with load-enable and asynchronous active-high reset
`FFLARN q_sig, d_sig, load_ena, rst_val, clk_sig, arstn_sig deprecated Flip-flop with load-enable and asynchronous active-low reset
`FFLSR q_sig, d_sig, load_ena, rst_val, clk_sig, rst_sig Flip-flop with load-enable and synchronous active-high reset
`FFLSRN q_sig, d_sig, load_ena, rst_val, clk_sig, rstn_sig Flip-flop with load-enable and synchronous active-low reset
`FFLNR q_sig, d_sig, load_ena, clk_sig Flip-flop with load-enable without reset
  • The name of the clock and reset signals for implicit variants is clk_i and rst_ni, respectively.
  • Argument suffix _sig indicates signal names for present and next state as well as clocks and resets.
  • Argument rst_val specifies the value literal to be assigned upon reset.
  • Argument load_ena specifies the boolean expression that forms the load enable of the register.

SystemVerilog Assertion Macros

The header file assertions.svh contains macros that expand to assertion blocks. These macros should recduce the effort in writing many assertions and make it easier to use them. They are identical with the macros used by lowrisc and just re-implemented here for the sake of easier use in PULP projects (the same include guard is used so they should not clash).

Simple Assertion and Cover Macros

Macro Arguments Description
`ASSERT_I __name, __prop Immediate assertion
`ASSERT_INIT __name, __prop Assertion in initial block. Can be used for things like parameter checking
`ASSERT_FINAL __name, __prop Assertion in final block
`ASSERT __name, __prop, (__clk, __rst) Assert a concurrent property directly
`ASSERT_NEVER __name, __prop, (__clk, __rst) Assert a concurrent property NEVER happens
`ASSERT_KNOWN __name, __sig, (__clk, __rst) Concurrent clocked assertion with custom error message
`COVER __name, __prop, (__clk, __rst) Cover a concurrent property
  • The name of the clock and reset signals for implicit variants is clk_i and rst_ni, respectively.

Complex Assertion Macros

Macro Arguments Description
`ASSERT_PULSE __name, __sig, (__clk, __rst) Assert that signal is an active-high pulse with pulse length of 1 clock cycle
`ASSERT_IF __name, __prop, __enable, (__clk, __rst) Assert that a property is true only when an enable signal is set
`ASSERT_KNOWN_IF __name, __sig, __enable, (__clk, __rst) Assert that signal has a known value (each bit is either '0' or '1') after reset if enable is set
  • The name of the clock and reset signals for implicit variants is clk_i and rst_ni, respectively.

Assumption Macros

Macro Arguments Description
`ASSUME __name, __prop, (__clk, __rst) Assume a concurrent property
`ASSUME_I __name, __prop Assume an immediate property
  • The name of the clock and reset signals for implicit variants is clk_i and rst_ni, respectively.

Formal Verification Macros

Macro Arguments Description
`ASSUME_FPV __name, __prop, (__clk, __rst) Assume a concurrent property during formal verification only
`ASSUME_I_FPV __name, __prop Assume a concurrent property during formal verification only
`COVER_FPV __name, __prop, (__clk, __rst) Cover a concurrent property during formal verification
  • The name of the clock and reset signals for implicit variants is clk_i and rst_ni, respectively.

More Repositories

1

axi

AXI SystemVerilog synthesizable IP modules and verification infrastructure for high-performance on-chip communication
SystemVerilog
1,007
star
2

pulpino

An open-source microcontroller system based on RISC-V
C
876
star
3

pulp-dronet

A deep learning-powered visual navigation engine to enables autonomous navigation of pocket-size quadrotor - running on PULP
C
491
star
4

pulpissimo

This is the top-level project for the PULPissimo Platform. It instantiates a PULPissimo open-source system with a PULP SoC domain, but no cluster.
SystemVerilog
381
star
5

ara

The PULP Ara is a 64-bit Vector Unit, compatible with the RISC-V Vector Extension Version 1.0, working as a coprocessor to CORE-V's CVA6 core
C
365
star
6

pulp

This is the top-level project for the PULP Platform. It instantiates a PULP open-source system with a PULP SoC (microcontroller) domain accelerated by a PULP cluster with 8 cores.
SystemVerilog
343
star
7

mempool

A 256-RISC-V-core system with low-latency access into shared L1 memory.
C
273
star
8

bender

A dependency management tool for hardware projects.
Rust
232
star
9

snitch

â›” DEPRECATED â›” Lean but mean RISC-V system!
SystemVerilog
218
star
10

cheshire

A minimal Linux-capable 64-bit RISC-V SoC built around CVA6
Verilog
194
star
11

riscv-dbg

RISC-V Debug Support for our PULP RISC-V Cores
SystemVerilog
183
star
12

FlooNoC

A Fast, Low-Overhead On-chip Network
SystemVerilog
131
star
13

pulp-sdk

C
99
star
14

hero

Heterogeneous Research Platform (HERO) for exploration of heterogeneous computers consisting of programmable many-core accelerators and an application-class host CPU, including full-stack software and hardware.
SystemVerilog
94
star
15

iDMA

A modular, parametrizable, and highly flexible Data Movement Accelerator (DMA)
SystemVerilog
89
star
16

pulp-nn

C
76
star
17

dory

A tool to deploy Deep Neural Networks on PULP-based SoC's
Python
76
star
18

carfield

A mixed-criticality platform built around Cheshire, with a number of safety/security and predictability features. Ready-to-use FPGA flow on multiple boards is available.
Tcl
72
star
19

pulp-riscv-gnu-toolchain

C
72
star
20

spatz

Spatz is a compact RISC-V-based vector processor meant for high-performance, small computing clusters.
C
71
star
21

register_interface

Generic Register Interface (contains various adapters)
SystemVerilog
68
star
22

pulp_soc

pulp_soc is the core building component of PULP based SoCs
SystemVerilog
63
star
23

morty

A SystemVerilog source file pickler.
Rust
51
star
24

snitch_cluster

An energy-efficient RISC-V floating-point compute cluster.
C
50
star
25

bigpulp

â›” DEPRECATED â›” RISC-V manycore accelerator for HERO, bigPULP hardware platform
SystemVerilog
50
star
26

axi_riscv_atomics

AXI Adapter(s) for RISC-V Atomic Operations
SystemVerilog
43
star
27

nemo

NEural Minimizer for pytOrch
Python
40
star
28

common_verification

SystemVerilog modules and classes commonly used for verification
SystemVerilog
39
star
29

pulp-runtime

Simple runtime for Pulp platforms
C
34
star
30

redmule

SystemVerilog
33
star
31

pulp-dsp

C
32
star
32

quantlab

Shell
32
star
33

RVfplib

Optimized RISC-V FP emulation for 32-bit processors
Assembly
31
star
34

pulp_cluster

The multi-core cluster of a PULP system.
SystemVerilog
31
star
35

fann-on-mcu

C
29
star
36

svase

C++
29
star
37

culsans

Tightly-coupled cache coherence unit for CVA6 using the ACE protocol
C
27
star
38

pulp-trainlib

Floating-Point Optimized On-Device Learning Library for the PULP Platform.
C
26
star
39

tech_cells_generic

Technology dependent cells instantiated in the design for generic process (simulation, FPGA)
SystemVerilog
25
star
40

clint

RISC-V Core Local Interrupt Controller (CLINT)
SystemVerilog
24
star
41

cheshire-ihp130-o

Tcl
24
star
42

stream-ebpc

Provides the hardware code for the paper "EBPC: Extended Bit-Plane Compression for Deep Neural Network Inference and Training Accelerators" by Lukas Cavigelli, Georg Rutishauser, Luca Benini.
SystemVerilog
23
star
43

axi_mem_if

Simple single-port AXI memory interface
SystemVerilog
23
star
44

uvm-components

Contains commonly used UVM components (agents, environments and tests).
SystemVerilog
22
star
45

hero-sdk

â›” DEPRECATED â›” HERO Software Development Kit
Shell
21
star
46

ri5cy_gnu_toolchain

Makefile
21
star
47

jtag_dpi

JTAG DPI module for SystemVerilog RTL simulations
SystemVerilog
21
star
48

fpu

SystemVerilog
21
star
49

axi_llc

SystemVerilog
20
star
50

neureka

2-8bit weights, 8-bit activations flexible Neural Processing Engine for PULP clusters
SystemVerilog
19
star
51

hyperbus

SystemVerilog
18
star
52

axi_spi_slave

SystemVerilog
18
star
53

quantlib

A library to train and deploy quantised Deep Neural Networks
Python
18
star
54

clic

RISC-V fast interrupt controller
SystemVerilog
18
star
55

axi_node

AXI X-Bar
SystemVerilog
17
star
56

serial_link

A simple, scalable, source-synchronous, all-digital DDR link
SystemVerilog
17
star
57

croc

A PULP SoC for education, easy to understand and extend with a full flow for a physical design.
SystemVerilog
16
star
58

banshee

Rust
16
star
59

occamy

A high-efficiency system-on-chip for floating-point compute workloads.
Python
16
star
60

rbe

Reconfigurable Binary Engine
SystemVerilog
15
star
61

sne

SystemVerilog
15
star
62

gvsoc

Pulp virtual platform
C++
15
star
63

axi_spi_master

SystemVerilog
15
star
64

hwpe-stream

IPs for data-plane integration of Hardware Processing Engines (HWPEs) within a PULP system
SystemVerilog
14
star
65

Deeploy

ONNX-to-C Compiler for Heterogeneous SoCs
Python
14
star
66

fpu_div_sqrt_mvp

[UNRELEASED] FP div/sqrt unit for transprecision
SystemVerilog
13
star
67

ne16

Neural Engine, 16 input channels
SystemVerilog
13
star
68

trace_debugger

Capture retired instructions of a RISC-V Core and compress them to a sequence of packets.
SystemVerilog
12
star
69

axi2apb

SystemVerilog
12
star
70

mibench

The MiBench testsuite, extended for use in general embedded environments
C
12
star
71

adv_dbg_if

Advanced Debug Interface
SystemVerilog
12
star
72

hci

Heterogeneous Cluster Interconnect to bind special-purpose HW accelerators with general-purpose cluster cores
SystemVerilog
12
star
73

trdb

RISC-V processor tracing tools and library
C
12
star
74

pulp-nn-mixed

C
11
star
75

pulp-freertos

FreeRTOS for PULP
C
11
star
76

ecg-tcn

Official code for ECG-TCN paper accepted for publication on AICAS2021
Python
11
star
77

safety_island

A reliable, real-time subsystem for the Carfield SoC
C
11
star
78

ELAU

SystemVerilog
10
star
79

jtag_pulp

Verilog
10
star
80

AI-deck-workshop

Assembly
10
star
81

pulp-debug-bridge

Tool to connect the workstation to the pulp targets abd interact with them
C++
10
star
82

hier-icache

SystemVerilog
10
star
83

quadrilatero

matrix-coprocessor for RISC-V
C
10
star
84

pulp-detector

C
10
star
85

chimera

Python
9
star
86

riscv-gnu-toolchain

GNU toolchain for PULP and RISC-V
C
9
star
87

gpio

Parametric GPIO Peripheral
SystemVerilog
9
star
88

cluster_interconnect

SystemVerilog
9
star
89

hwpe-mac-engine

An example Hardware Processing Engine
SystemVerilog
9
star
90

obi

OBI SystemVerilog synthesizable interconnect IPs for on-chip communication
SystemVerilog
9
star
91

ITA

SystemVerilog
9
star
92

pulp-rt-examples

C
8
star
93

fpu_ss

CORE-V eXtension Interface compliant RISC-V [F|Zfinx] Coprocessor
SystemVerilog
8
star
94

pulp-builder

Shell
8
star
95

apb_timer

APB Timer Unit
SystemVerilog
8
star
96

pulp-transformer

C
8
star
97

redundancy_cells

SystemVerilog IPs and Modules for architectural redundancy designs.
SystemVerilog
8
star
98

pulp-ethernet

SystemVerilog
8
star
99

dram_rtl_sim

SystemVerilog
8
star
100

pulp-actions

Python
7
star