exo
Exocompilation for productive programming of hardware accelerators
Science Score: 67.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 2 DOI reference(s) in README -
✓Academic publication links
Links to: arxiv.org, acm.org -
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (16.5%) to scientific vocabulary
Repository
Exocompilation for productive programming of hardware accelerators
Basic Info
- Host: GitHub
- Owner: exo-lang
- License: mit
- Language: Python
- Default Branch: main
- Homepage: https://godbolt.exo-lang.dev/
- Size: 40.1 MB
Statistics
- Stars: 654
- Watchers: 14
- Forks: 47
- Open Issues: 126
- Releases: 5
Metadata Files
README.md
Basics
Install Exo
We support Python versions 3.9 and above.
If you're just using Exo, install it using pip:
sh
$ pip install exo-lang
In case of ModuleNotFoundError: No module named 'attrs' please upgrade your attrs module by pip install --upgrade attrs.
Compile Exo
Exo files can be directly executed with Python:
sh
$ python exo_file.py
To generate C and header files, use exocc command:
sh
$ exocc exo_file.py
Running the command will generate two files: exo_file.c and exo_file.h. These files will be created in a directory called exo_file/ by default.
You can use optional arguments to customize the output:
- The -o argument allows you to specify a different directory name.
- The --stem argument allows you to specify custom names for the C file and header file.
Build Exo from source
We make active use of newer Python 3.x features. Please use Python 3.9 or 3.10 if you're getting errors about unsupported features.
Setting up Exo for development is like any other Python project. We strongly recommend you use a virtual environment.
$ git clone git@github.com:exo-lang/exo.git
$ cd exo/
$ git submodule update --init --recursive
$ python -m venv ~/.venv/exo
$ source ~/.venv/exo/bin/activate
(exo) $ python -m pip install -U pip setuptools wheel
(exo) $ python -m pip install -r requirements.txt
(exo) $ pre-commit install
This will make sure you have the submodules checked out and that the pre-commit scripts (that run an autoformatter, maybe other tools in the future) run.
Finally, you can build and install Exo.
(exo) $ python -m build .
(exo) $ pip install dist/*.whl
PySMT
Depending on your setup, getting PySMT to work correctly may be difficult. You
need to independently install a solver such as Z3 or CVC4, and even then getting
the PySMT library to correctly locate that solver may be difficult. We have
included the z3-solver package as a requirement, which will hopefully avoid
this issue, but you can also install z3 (or your choice of solver)
independently.
Notes for Testing
Dependencies
Build system (required)
The Exo test harness generates C code and as such needs to compile and link using an unknown (i.e. system) compiler. To do this, it generates CMake build files and invokes CMake behind the scenes.
Therefore, you must have CMake 3.21 or newer installed.
By default, CMake will use Ninja as its backend, but
this may be overridden by setting the environment variable CMAKE_GENERATOR
to Unix Makefiles, in case you do not wish to install Ninja.
SDE (optional)
For testing x86 features on processors which don't support them (e.g., AVX-512
or AMX), we rely on
the Intel Software Development Emulator
as an optional dependency. Tests which rely on this (namely for AMX) look
for sde64 either in the path defined by the SDE_PATH environment variable or
in the system PATH, and are skipped if it is not available.
Running tests
To run the tests, simply type
pytest
in the root of the project.
Running Coverage Testing
To run pytest with coverage tests, execute
pytest --cov=./ --cov-report=html
Then, if you want to see annotated source files, open ./htmlcov/index.html.
Learn about Exo
Take a look at the examples directory for scheduling examples and the documentation directory for various documentation about Exo.
Contact
Please contact exo@mit.edu or yuka@csail.mit.edu if you have any questions.
Publication
Exo's major contributions and ideas are published in the following two papers. The gist of its design principles and features is summarized in Design.md.
- Exocompilation for Productive Programming of Hardware Accelerators\ Yuka Ikarashi*, Gilbert Louis Bernstein*, Alex Reinking, Hasan Genc, Jonathan Ragan-Kelley\ PLDI 2022\ The full version with appendices can be found here.
- Exo 2: Growing a Scheduling Language\ Yuka Ikarashi, Kevin Qian, Samir Droubi, Alex Reinking, Gilbert Bernstein, Jonathan Ragan-Kelley\ ASPLOS 2025\ The full version with appendices can be found here.
If you use Exo, please cite both the compiler and the papers!
Owner
- Name: exo-lang
- Login: exo-lang
- Kind: organization
- Repositories: 5
- Profile: https://github.com/exo-lang
Citation (CITATION.cff)
cff-version: 1.2.0
title: Exo Programming Language
message: If you use Exo, please cite both the compiler and the paper.
type: software
authors:
# These are the authors of the compiler implementation, not of the paper.
# They were determined by inspecting the git commit history and contribution
# graph, here: https://github.com/exo-lang/exo/graphs/contributors
- given-names: Yuka
family-names: Ikarashi
orcid: https://orcid.org/0000-0001-5255-0918
- given-names: Alex
family-names: Reinking
orcid: https://orcid.org/0000-0003-3285-2112
- given-names: Gilbert Louis
family-names: Bernstein
orcid: https://orcid.org/0000-0002-3016-1169
- given-names: Kevin
family-names: Qian
- given-names: Samir
family-names: Droubi
- given-names: Jonathan
family-names: Ragan-Kelley
orcid: https://orcid.org/0000-0001-6243-9543
repository-code: https://github.com/exo-lang/exo
url: https://exo-lang.dev
license: MIT
# These fields should point to the latest release and be updated as soon as a
# new release is tagged.
commit: 09e666ee0690797a6c56103b65f5d83abd79c60e
version: 1.0.0
date-released: 2024-11-05
# This is the citation for the PLDI 2022 paper.
preferred-citation:
type: conference-paper
title: Exocompilation for Productive Programming of Hardware Accelerators
authors:
- given-names: Yuka
family-names: Ikarashi
orcid: https://orcid.org/0000-0001-5255-0918
- given-names: Gilbert Louis
family-names: Bernstein
orcid: https://orcid.org/0000-0002-3016-1169
- given-names: Alex
family-names: Reinking
orcid: https://orcid.org/0000-0003-3285-2112
- given-names: Hasan
family-names: Genc
orcid: https://orcid.org/0000-0002-6884-941X
- given-names: Jonathan
family-names: Ragan-Kelley
orcid: https://orcid.org/0000-0001-6243-9543
year: 2022
collection-title: >-
Proceedings of the 43rd ACM SIGPLAN International Conference on Programming
Language Design and Implementation
collection-doi: 10.1145/3519939
# editors:
# - family-names: Kirk
# given-names: James T.
conference:
name: >-
43rd ACM SIGPLAN International Conference on Programming Language Design
and Implementation
# location: Spocks Inn Hotel and Bar
# address: 123 Main St
city: San Diego
# region: Jarvis Island
# post-code: 12345
country: US
date-start: 2022-06-13
date-end: 2022-06-17
start: 703
end: 718
doi: 10.1145/3519939.3523446
GitHub Events
Total
- Create event: 69
- Release event: 1
- Issues event: 10
- Watch event: 305
- Delete event: 43
- Member event: 2
- Issue comment event: 103
- Push event: 460
- Pull request event: 115
- Pull request review comment event: 56
- Pull request review event: 66
- Fork event: 21
Last Year
- Create event: 69
- Release event: 1
- Issues event: 10
- Watch event: 305
- Delete event: 43
- Member event: 2
- Issue comment event: 103
- Push event: 460
- Pull request event: 115
- Pull request review comment event: 56
- Pull request review event: 66
- Fork event: 21
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 161
- Total pull requests: 401
- Average time to close issues: 11 months
- Average time to close pull requests: 18 days
- Total issue authors: 18
- Total pull request authors: 24
- Average comments per issue: 1.25
- Average comments per pull request: 1.44
- Merged pull requests: 291
- Bot issues: 1
- Bot pull requests: 116
Past Year
- Issues: 13
- Pull requests: 131
- Average time to close issues: about 1 month
- Average time to close pull requests: 7 days
- Issue authors: 6
- Pull request authors: 15
- Average comments per issue: 0.54
- Average comments per pull request: 1.08
- Merged pull requests: 75
- Bot issues: 1
- Bot pull requests: 77
Top Authors
Issue Authors
- yamaguchi1024 (67)
- SamirDroubi (29)
- alexreinking (14)
- skeqiqevian (14)
- gilbo (9)
- rachitnigam (6)
- jrk (4)
- akeley98 (2)
- ybai62868 (2)
- j-c-w (1)
- pkanhaiy (1)
- TJU-PanYizhe (1)
- a0u (1)
- pipplo (1)
- kehemo (1)
Pull Request Authors
- dependabot[bot] (175)
- yamaguchi1024 (134)
- skeqiqevian (85)
- SamirDroubi (83)
- adcastel (12)
- alexreinking (11)
- akeley98 (8)
- kehemo (7)
- rachitnigam (5)
- rtzam (4)
- eyr1n (4)
- andrewdalex (2)
- jasondavies (2)
- panther03 (2)
- evmar (2)
Top Labels
Issue Labels
Pull Request Labels
Dependencies
- actions/checkout v3 composite
- actions/setup-python v2 composite
- DoozyX/clang-format-lint-action v0.13 composite
- EndBug/add-and-commit v4 composite
- actions/checkout v2 composite
- psf/black stable composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- codecov/codecov-action v2 composite
- lukka/get-cmake v3.21.2 composite
- petarpetrovt/setup-sde v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- pypa/gh-action-pypi-publish master composite
- Pillow ==9.3.0
- PySMT ==0.9.0
- asdl ==0.1.5
- asdl-adt ==0.1.0
- astor ==0.8.1
- black ==22.10.0
- build ==0.7.0
- coverage ==6.3.2
- jupyter-contrib-nbextensions ==0.5.1
- numpy ==1.23.4
- pre-commit ==2.20.0
- pytest ==7.1.1
- pytest-cov ==3.0.0
- pytest-xdist ==3.0.2
- tox ==3.24.5
- yapf ==0.32.0
- z3-solver ==4.8.15.0
- actions/checkout v3 composite
- actions/setup-python v4 composite