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.9894-cp314-cp314-manylinux_2_34_x86_64.whl (84.5 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ x86-64

xls_python-0.1.9894-cp313-cp313-manylinux_2_34_x86_64.whl (84.5 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ x86-64

xls_python-0.1.9894-cp312-cp312-manylinux_2_34_x86_64.whl (84.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

xls_python-0.1.9894-cp311-cp311-manylinux_2_34_x86_64.whl (84.5 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ x86-64

xls_python-0.1.9894-cp310-cp310-manylinux_2_34_x86_64.whl (84.5 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ x86-64

File details

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

File metadata

File hashes

Hashes for xls_python-0.1.9894-cp314-cp314-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 b3ab52be089b47831c7caaff935de48dfe6b4cb7a7bb9bf1996abf5812b0fd5d
MD5 06f46923fffbb4e45903edb738f6552e
BLAKE2b-256 ea3d05327996c589fd4164e787484d04caddd2e2022aa8034b35bdf79f226eb4

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9894-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.9894-cp313-cp313-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9894-cp313-cp313-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 fb152653cec02ae45f7bbdbd6190558775c316af509e6f8c90d670652147dee5
MD5 4513e37aa969e6bfe1bc3b769c0ac92c
BLAKE2b-256 c46424cdef56e2bc300cf6beadfab0f67342b5bea3a1b454cd5778be4a986233

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9894-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.9894-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9894-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 ca3031510a7d223a726848a005e3b39572455967e5f04e68458fa3f19cf3e540
MD5 434f4eecae13f0d211b847ab6039f188
BLAKE2b-256 4b92e4e51e439fcdb0913a4170b8066ccf718e78db66466f5ecea43af1a815f0

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9894-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.9894-cp311-cp311-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9894-cp311-cp311-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 7e0b25e25e0933c00ed24658d0e66ff79ea00175bad8a7b0a3069245becb3eb3
MD5 7041064d33c956687aae25cb94549802
BLAKE2b-256 2d97969ab70bb398a86d40cf51290134eb6b98ed7499ed2008f8fe8a210bff5f

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9894-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.9894-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for xls_python-0.1.9894-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 16be383e79629476801b5f9f58a0c336ca35123d7442187bffd4e49910403c40
MD5 4b26e6ab9e25e6c468b200388848da36
BLAKE2b-256 0fa9625176ba3c6659db29ec025997f78053c8577365d1c3879f2d2376268dc8

See more details on using hashes here.

Provenance

The following attestation bundles were made for xls_python-0.1.9894-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