Skip to main content

Python binding for XLS

Project description

pyxls

Documentation PyPI LGPLv3

Python bindings for the XLS (eXtensible Logic Synthesis) compiler infrastructure.

[!NOTE] pyxls is a third-party project interfacing with the XLS C API. It is not affiliated, endorsed, or maintained by the XLS team at Google.

[!WARNING] pyxls is in development. The API is not stable and may change without deprecation.

Installation

pip install xls-python

Or from source (requires a C++20 compiler, Meson, and Ninja):

pip install .

Quick Start

from xls import Package, Value

IR = """
package my_pkg

top fn add(x: bits[32], y: bits[32]) -> bits[32] {
  ret add.3: bits[32] = add(x, y, id=3)
}
"""

pkg = Package.parse_ir(IR)
fn = pkg.get_function('add')
result = fn.interpret([Value.make_ubits(32, 3), Value.make_ubits(32, 4)])
print(result.to_string())  # bits[32]:7

Documentation

See https://calad0i.github.io/pyxls/ for full documentation.

License

Apache 2.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

xls_python-0.1.9903-cp314-cp314-manylinux_2_34_x86_64.whl (84.4 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ x86-64

xls_python-0.1.9903-cp313-cp313-manylinux_2_34_x86_64.whl (84.4 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ x86-64

xls_python-0.1.9903-cp312-cp312-manylinux_2_34_x86_64.whl (84.4 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

xls_python-0.1.9903-cp311-cp311-manylinux_2_34_x86_64.whl (84.4 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ x86-64

xls_python-0.1.9903-cp310-cp310-manylinux_2_34_x86_64.whl (84.4 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ x86-64

File details

Details for the file xls_python-0.1.9903-cp314-cp314-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9903-cp314-cp314-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 1007aec37b9b1cee6eda01af46f8cbcdf6a2220d7ebf2c8a689ca1a17f578845
MD5 1be6197cf7611c2987434637d0b8e8d6
BLAKE2b-256 22ac75276bb00b890640f31b1b8931d6c725c7d621adf8411ae4a0b9c75dd328

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9903-cp314-cp314-manylinux_2_34_x86_64.whl:

Publisher: python-publish.yml on calad0i/pyxls

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file xls_python-0.1.9903-cp313-cp313-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9903-cp313-cp313-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 82a4ba2d0f68b9f827c0e68d4f0bf4cfad8f7b3ddc6c2e1a7a042356588409cd
MD5 bc1ce95590e616880d02e697eb8f880c
BLAKE2b-256 98cdd39609f16d442e4d7e6f082ec68aaa3494d23b5fb6f0cd0028b9d32038f3

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9903-cp313-cp313-manylinux_2_34_x86_64.whl:

Publisher: python-publish.yml on calad0i/pyxls

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file xls_python-0.1.9903-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9903-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 4954e943b180cb191ae17ee3fe966d097dcd8a155caae01c47880db8b26f7279
MD5 e074f108f4322fe20b1b680ae53bca4a
BLAKE2b-256 fd37c24d77c7d5fdca600070c6aa379f9c25c3eba80c37faf27c051c71485fa4

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9903-cp312-cp312-manylinux_2_34_x86_64.whl:

Publisher: python-publish.yml on calad0i/pyxls

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file xls_python-0.1.9903-cp311-cp311-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9903-cp311-cp311-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 8dc60729ebca417f76e491fd4ddfc765223b30c2e8f81e092979ada016ec7d7a
MD5 c11c82489e8a4f940d2d0713c7183581
BLAKE2b-256 97d8e05022204528ab9487ffba397a6f99a273a17c662ae04f3a708d9a445bdc

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9903-cp311-cp311-manylinux_2_34_x86_64.whl:

Publisher: python-publish.yml on calad0i/pyxls

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file xls_python-0.1.9903-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9903-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 556d9d0b395af88e21ed33685cd5dddc98deed8ff91d3bada5fcfa3d61a64bbe
MD5 0e31901b1d33b645d0a5e807f103a0c3
BLAKE2b-256 cfaae3d7fad53cd2eb009ca06535767176ca60bc60e8cd172ccf3dd79a998e94

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9903-cp310-cp310-manylinux_2_34_x86_64.whl:

Publisher: python-publish.yml on calad0i/pyxls

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page