/Googles XLS: Accelerated HW Synthesis

Googles XLS: Accelerated HW Synthesis

XLS Logo

What is XLS?

The XLS (Accelerated HW Synthesis) project aims to enable the rapid development
of hardware IP that also runs as efficient host software via “software
style” methodology.

XLS implements a High Level Synthesis (HLS) toolchain which produces
synthesizable designs from flexible, high-level descriptions of functionality.
It is fully Open Source: Apache 2 licensed and developed via GitHub.

XLS is used inside of Google for generating feed-forward pipelines from
“building block” routines / libraries that can be easily retargeted, reused, and
composed in a latency-insensitive manner.

Not yet available, but active work in progress is the implementation of XLS
concurrent processes, in Communicating Sequential Processes (CSP) style, that
allow pipelines to communicate with each other and induct over time.

XLS is still experimental, undergoing rapid development, and not an officially
supported Google product. Expect bugs and sharp edges. Please help by trying it
out, reporting bugs, and letting us know
what you think!

Building From Source

Currently, XLS must be built from source using the Bazel build system.

Note: Binary distributions of the XLS library are not currently available, but
we hope to enable them via continuous integration, see this issue.

The following instructions are for the Ubuntu 20.04 (Focal) Linux distribution.
Note that we start by assuming Bazel has been

# Follow the bazel install instructions:
# https://docs.bazel.build/versions/master/install-ubuntu.html
# Afterwards we observe:

$ bazel --version
bazel 3.2.0

$ sudo apt install python3-dev python3-distutils python3-dev libtinfo5

# py_binary currently assume they can refer to /usr/bin/env python
# even though Ubuntu 20.04 has no `python`, only `python3`.
# See https://github.com/bazelbuild/bazel/issues/8685

$ mkdir -p $HOME/opt/bin/
$ ln -s $(which python3) $HOME/opt/bin/python
$ echo 'export PATH=$HOME/opt/bin:$PATH' >> ~/.bashrc
$ source ~/.bashrc

$ bazel test -c opt ...

A reference build/test environment setup is also provided via Dockerfile:

~$ git clone https://github.com/google/xls.git
~$ cd xls
~/xls$ docker build .  # Performs optimized build and test.

Stack Diagram and Project Layout

Navigating a new code base can be daunting; the following description provides a
high-level view of the important directories and their intended organization /
purpose, and correspond to the components in this XLS stack diagram:

XLS Stack Diagram

Discussions about XLS – development, debugging, usage, and anything else –
should go to the xls-dev mailing list.


The following are
contributors to the XLS
project, see our
contributing documentation and
good first issues!

Original Source