Code Monkey home page Code Monkey logo

blarney's Introduction


Blarney logo
Blarney logo

Blarney is a Haskell library for hardware description that builds a range of HDL abstractions on top of a small set of pure functional circuit primitives. It is a modern variant of Lava using many of the latest features of GHC. Some aspects of the library are also inspired by Bluespec, such as first-class actions and method-based interfaces.

Prerequisites

We’ll need Verilator and GHC 9.2.1 or later.

On Ubuntu 20.04, we can do:

$ sudo apt install verilator libgmp-dev

For GHC 9.2.1 or later, ghcup can be used.

Quick start

To clone the repo:

$ git clone --recursive https://github.com/blarney-lang/blarney

To simulate the Sorter example from Blarney’s Examples directory:

$ cd blarney/Examples/Sorter
$ make                  # Build the example using GHC
$ ./Sorter              # Generate Verilog for the example
$ cd Sorter-Verilog     # Go to the generated Verilog
$ make                  # Compile the generated Verilog using Verilator
$ ./Sorter              # Simulate the generated Verilog

You should see the output:

sort [3,4,1,0,2] = [0,1,2,3,4]

To run the regression test suite:

$ cd blarney/Test
$ ./test.sh --run-all

To start development of your own Blarney application or library, take a look at the Blarney template project.

Documentation

See Blarney by Example, our introduction to Blarney, which supplements the Haddock docs.

Applications

Our current list of applications developed using Blarney:

  • Actora: A 3-stage stack processor that runs code written a subset of Erlang. It has higher performance density than Intel’s register-based NIOS-II core for compiled Erlang code.

  • SIMTight: A CHERI-enabled RISC-V GPGPU with dynamic scalarisation features and high performance density on Intel’s Stratix 10 FPGA.

blarney's People

Contributors

dillonhuff avatar gameboo avatar jonasalaif avatar mn416 avatar ret avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.