Crates.io | py-codegen-llvm |
lib.rs | py-codegen-llvm |
version | |
source | src |
created_at | 2024-06-07 03:49:27.687823 |
updated_at | 2024-10-17 07:41:07.169403 |
description | llvm codegen backend implementation for Pin1Yin1 |
homepage | |
repository | https://github.com/pin1yin1yu3yan2/Pin1Yin1-Compiler-Rust |
max_upload_size | |
id | 1264369 |
Cargo.toml error: | TOML parse error at line 18, column 1 | 18 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include` |
size | 0 |
Pin1Yin1Yu3Yan2's compiler written in rust.
There are two code generation backends: llvm
and c
. By default, both are enabled. You can disable all of them by using the --no-default-features
flag.
e.g. enable c backend only
cargo build --release --no-default-features --features=backend-c
The version of llvm is llvm@18
, by default, it's preferred to dynamic link to the system's llvm library.
If you want to use a different version of llvm, or you want to statically link to the llvm library, you can order the feature flags of inkwell
cargo build --release --no-default-features --features=backend-llvm,inkwell/llvm18-0-force-static
Enable the feature flag backend-llvm
to not enough to compile, you must also enable one of the inkwell
feature flags.
C backend is just a code printer, it doesn't need any extra dependencies.
default
: Enable all features follow, and inkwell/llvm18-0-prefer-dynamic
.backend-llvm
: Enable llvm backend.backend-c
: Enable c backend.parallel-declare
: Enable parallel type declaration of items(like functions)./opt/llvm
and only dynamic library is provided. If you want to compile and use llvm backend, you must set the LD_LIBRARY_PATH
to /opt/llvm/lib
.