Skip to main content

Wasmer logo Wasmer Python, the Singlepass compiler PyPI version Wasmer Python Documentation Wasmer PyPI downloads Wasmer Slack Channel

wasmer is a complete and mature WebAssembly runtime for Python. wasmer_compiler_singlepass provides the Singlepass compiler to wasmer, so that wasmer is able to compile WebAssembly module.

Other compilers exist:

  • wasmer_compiler_cranelift,
  • wasmer_compiler_llvm.

To get a more complete view, please see the documentation of the wasmer package itself.

Install

This package must be used with the wasmer package, thus:

$ pip install wasmer
$ pip install wasmer_compiler_singlepass

Usage

Any engines in wasmer.engine can take the wasmer_compiler_singlepass.Compiler class as argument:

from wasmer import engine, Store, Module, Instance
from wasmer_compiler_singlepass import Compiler

# Let's use the Singlepass compiler with the JIT engine…
store = Store(engine.JIT(Compiler))

# … or with the native engine!
store = Store(engine.Native(Compiler))

# And now, compile the module.
module = Module(store, open('my_program.wasm', 'rb').read())

# Now it's compiled, let's instantiate it.
instance = Instance(module)

# And get fun, for example by calling the `sum` exported function!
print(instance.exports.sum(1, 2))

Documentation

Browse the documentation at https://wasmerio.github.io/wasmer-python/api/wasmer_compiler_singlepass/.

Alternatively, run just build compiler-singlepass followed by just doc to generate the documentation inside docs/api/wasmer_compiler_singlepass.html.

Metadata

Release files for wasmer-compiler-singlepass 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for wasmer-compiler-singlepass 1.1.0
File
wasmer_compiler_singlepass-1.1.0-py3-none-any.whl Python 3 none any Details
wasmer_compiler_singlepass-1.1.0-cp310-none-win_amd64.whl CPython 3.10 none Windows x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp310-cp310-manylinux_2_24_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.24+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp310-cp310-macosx_10_7_x86_64.whl CPython 3.10 CPython 3.10 macOS 10.7+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp39-none-win_amd64.whl CPython 3.9 none Windows x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp39-cp39-manylinux_2_24_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.24+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp39-cp39-macosx_10_7_x86_64.whl CPython 3.9 CPython 3.9 macOS 10.7+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp38-none-win_amd64.whl CPython 3.8 none Windows x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp38-cp38-manylinux_2_24_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.24+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp38-cp38-macosx_10_7_x86_64.whl CPython 3.8 CPython 3.8 macOS 10.7+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp37-none-win_amd64.whl CPython 3.7 none Windows x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp37-cp37m-manylinux_2_24_x86_64.whl CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.24+ x86-64 Details
wasmer_compiler_singlepass-1.1.0-cp37-cp37m-macosx_10_7_x86_64.whl CPython 3.7 CPython 3.7 pymalloc macOS 10.7+ x86-64 Details

Total release size: 7.0 MB

Release files / wasmer_compiler_singlepass-1.1.0-py3-none-any.whl

Download URL wasmer_compiler_singlepass-1.1.0-py3-none-any.whl
Size 1.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b323710db2c595d649b787d841cc38f5b4d8d353390225fedb765738f23ebe6f
BLAKE2b-256 checksum
How to use checksums
398ddda1b8f637845cc47c57362fa17cd7eaadc5d4b648abba3434d69e7edda0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp310-none-win_amd64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp310-none-win_amd64.whl
Size 539.0 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
ec567ac17f9296f4d61cc7c9936d00a042fe5fe7a51ce0bf7581f78d70dd6e68
BLAKE2b-256 checksum
How to use checksums
d09536801deb030fcb25c54c8e70ae9fe147a3fcff5410f76ae8cf40d0325f46
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp310-cp310-manylinux_2_24_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp310-cp310-manylinux_2_24_x86_64.whl
Size 635.9 kB
Tags CPython 3.10 Linux glibc 2.24+ x86-64
SHA-256 checksum
How to use checksums
6a5eacd1f92f9c5e4d2c3d90ed5a99bad4a6e8934c4e1b844609c493f5e1e3b8
BLAKE2b-256 checksum
How to use checksums
4e5d6b125a26e4922a6e059d2c4ee9f034aad38411b9d9e2c923bfb08971493b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp310-cp310-macosx_10_7_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp310-cp310-macosx_10_7_x86_64.whl
Size 574.4 kB
Tags CPython 3.10 macOS 10.7+ x86-64
SHA-256 checksum
How to use checksums
5fd7bfc7ac64e05b0452786f8c5e876e323f1cfc2530119a2178373707cc72bb
BLAKE2b-256 checksum
How to use checksums
738d16e7acc708784e2e9c8ffb6d21a88a331c85c32d54456832f6ceadea4765
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp39-none-win_amd64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp39-none-win_amd64.whl
Size 538.9 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
1fd0dacb11bb0f38ad1cbbcfd619dbb56bbc094fefed3f41caf4661e58118892
BLAKE2b-256 checksum
How to use checksums
32e77258ad655eb094400760bd29ddaa508d037a1f3c0de10efa726ef2980bef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp39-cp39-manylinux_2_24_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp39-cp39-manylinux_2_24_x86_64.whl
Size 636.1 kB
Tags CPython 3.9 Linux glibc 2.24+ x86-64
SHA-256 checksum
How to use checksums
a2e6ddb828577a64f828b2494e851579ec5df06359b32592ce4b3976a902691c
BLAKE2b-256 checksum
How to use checksums
9890b06da4fd5b8ab5ef9766f98d8a17827b86faee575398025a87d55493caea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp39-cp39-macosx_10_7_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp39-cp39-macosx_10_7_x86_64.whl
Size 574.6 kB
Tags CPython 3.9 macOS 10.7+ x86-64
SHA-256 checksum
How to use checksums
45bf078e07053544c75b1e866d262e1970f362182da92a8b5ace127e58108137
BLAKE2b-256 checksum
How to use checksums
dafaa0f227a8bd67ad04214b2645ef67381fe7f40e0aa37786daafb7dc288dcf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp38-none-win_amd64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp38-none-win_amd64.whl
Size 539.0 kB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
0ed07e261ae23f2e769ec314efd8eb3d6f1907b31856c3e0631b5b8b1cac3a10
BLAKE2b-256 checksum
How to use checksums
1770b0cd26915c4706b67bc7961236fbd2eb5e8c8d27ce40d240bbb3e5ba32f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp38-cp38-manylinux_2_24_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp38-cp38-manylinux_2_24_x86_64.whl
Size 635.7 kB
Tags CPython 3.8 Linux glibc 2.24+ x86-64
SHA-256 checksum
How to use checksums
5d1a60dc45bfb5a15b40070a24b34ffd09d457368fd2f1349bdb81c8bbb551e8
BLAKE2b-256 checksum
How to use checksums
62320e04e04933063fa890469c415a6045ebc31a6d85edbd794878ee30961cc1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp38-cp38-macosx_10_7_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp38-cp38-macosx_10_7_x86_64.whl
Size 574.4 kB
Tags CPython 3.8 macOS 10.7+ x86-64
SHA-256 checksum
How to use checksums
72362384b1f0ab2a44004cf9381f5445fed004821ddb1ee49d9f61113b566478
BLAKE2b-256 checksum
How to use checksums
76f1ebbee7f39d7ba934bec113cd78e1e5d022d4918c0e179da07d26e2dce7dd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp37-none-win_amd64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp37-none-win_amd64.whl
Size 539.0 kB
Tags CPython 3.7 Windows x86-64
SHA-256 checksum
How to use checksums
a6ad96bd4602c94b87a87861749c34206ae623b296bb290482c654e42692a377
BLAKE2b-256 checksum
How to use checksums
82a9a3940a93f4c5234ac68bf2efe45935b2d3c5f99169da66b14a34bc7a6250
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp37-cp37m-manylinux_2_24_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp37-cp37m-manylinux_2_24_x86_64.whl
Size 635.7 kB
Tags CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.24+ x86-64
SHA-256 checksum
How to use checksums
d240a7c3dafcf134aa95e46c50b464e24c23d04136a38bf4501ac776a7c09714
BLAKE2b-256 checksum
How to use checksums
01c48c598d2b743b2d1bbeb3a028d93886573e20bfe8a51d00a270421c9692bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

Release files / wasmer_compiler_singlepass-1.1.0-cp37-cp37m-macosx_10_7_x86_64.whl

Download URL wasmer_compiler_singlepass-1.1.0-cp37-cp37m-macosx_10_7_x86_64.whl
Size 574.5 kB
Tags CPython 3.7 CPython 3.7 pymalloc macOS 10.7+ x86-64
SHA-256 checksum
How to use checksums
dc55c7fc87742f02b6879c313a916fbfadd55037163da876fb8f8f6789a52a1b
BLAKE2b-256 checksum
How to use checksums
f1d7461f0d0448694d086b73a914f5f98b2ada67db81d91d7d0ea26cd3fd8db6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page