13 releases (6 breaking)

0.7.1 Feb 29, 2024
0.6.1 Oct 15, 2023
0.6.0 Aug 31, 2023
0.4.0 Jul 21, 2023
0.1.1 Aug 30, 2021

#246 in Programming languages

Download history 14/week @ 2024-02-19 162/week @ 2024-02-26 14/week @ 2024-03-04 20/week @ 2024-03-11 178/week @ 2024-04-01

199 downloads per month
Used in futil

Custom license

3MB
84K SLoC

SystemVerilog 42K SLoC // 0.0% comments Rust 29K SLoC // 0.1% comments Python 12K SLoC // 0.2% comments JavaScript 275 SLoC // 0.1% comments Pest 272 SLoC // 0.1% comments TCL 95 SLoC // 0.4% comments Vim Script 69 SLoC Emacs Lisp 65 SLoC // 0.3% comments Shell 35 SLoC // 0.2% comments Lua 29 SLoC // 0.1% comments TypeScript 22 SLoC // 0.2% comments INI 11 SLoC

Built with Depot

A Compiler Infrastructure for Accelerator Generators

Calyx is an intermediate language and infrastructure for building compilers that generate custom hardware accelerators.

See the Calyx website, language documentation and the documentation for the source code for more information. Calyx's design is based on our paper.

Installation

Quick

If you want to try out the compiler, install it using cargo:

cargo install calyx

This will install the calyx binary can optimize and compile Calyx programs to Verilog or CIRCT.

Follow the getting started instructions.

Organization

This repository contains the source code for the following:

  • calyx-utils: Utilities for the Calyx compiler
  • calyx-frontend: Parser and frontend AST for the Calyx language.
  • calyx-ir: The Calyx intermediate language.
  • calyx-opt: Optimizations for the Calyx intermediate language.
  • calyx: The Calyx compiler driver.

You can also use the Calyx compiler as a library and implement your own optimizations. To do this, check out the example provided by the calyx-opt crate.

Dependencies

~9.5MB
~169K SLoC