slang is a software library that provides various components for lexing, parsing, type checking, and elaborating SystemVerilog code. It comes with an executable tool that can compile and statically analyze any SystemVerilog project, but it is also intended to be usable as a front end for synthesis tools, simulators, linters, code editors, and refactoring tools.
slang is the fastest and most compliant SystemVerilog frontend (according to the open source chipsalliance test suite).
Full documentation is available on the website: https://sv-lang.com
Some examples of things you can use slang for:
Pre-built binaries for Linux, macOS, and Windows are available on the releases page.
Instructions on building slang from source are here. The tl;dr is:
git clone https://github.com/MikePopoloski/slang.git
cd slang
cmake -B build
cmake --build build -j
The slang binary can be run on your code right out of the box; check out the user manual for more information about how it works.
If you're looking to use slang as a library, please read through the developer guide.
The project also includes Python bindings for the library, which can be installed via PyPI:
pip install pyslang
See the pyslang directory in this repository for tests and examples that show how to use the Python API.
Experiment with parsing, type checking, and error detection live on the web (inspired by Matt Godbolt's excellent Compiler Explorer).
If you encounter a bug, have questions, or want to contribute, please get in touch by opening a GitHub issue or discussion thread.
Contributions are welcome, whether they be in the form of bug reports, comments, suggestions, documentation improvements, or full fledged new features via pull requests.
slang is licensed under the MIT license:
Copyright (c) 2015-2026 Michael Popoloski
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
(top 30 of 88)
C++
95.4%
Python
3.1%
slang is a software library that provides various components for lexing, parsing, type checking, and elaborating SystemVerilog code. It comes with an executable tool that can compile and statically analyze any SystemVerilog project, but it is also intended to be usable as a front end for synthesis tools, simulators, linters, code editors, and refactoring tools.
slang is the fastest and most compliant SystemVerilog frontend (according to the open source chipsalliance test suite).
Full documentation is available on the website: https://sv-lang.com
Some examples of things you can use slang for:
Pre-built binaries for Linux, macOS, and Windows are available on the releases page.
Instructions on building slang from source are here. The tl;dr is:
git clone https://github.com/MikePopoloski/slang.git
cd slang
cmake -B build
cmake --build build -j
The slang binary can be run on your code right out of the box; check out the user manual for more information about how it works.
If you're looking to use slang as a library, please read through the developer guide.
The project also includes Python bindings for the library, which can be installed via PyPI:
pip install pyslang
See the pyslang directory in this repository for tests and examples that show how to use the Python API.
Experiment with parsing, type checking, and error detection live on the web (inspired by Matt Godbolt's excellent Compiler Explorer).
If you encounter a bug, have questions, or want to contribute, please get in touch by opening a GitHub issue or discussion thread.
Contributions are welcome, whether they be in the form of bug reports, comments, suggestions, documentation improvements, or full fledged new features via pull requests.
slang is licensed under the MIT license:
Copyright (c) 2015-2026 Michael Popoloski
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
(top 30 of 88)
C++
95.4%
Python
3.1%