[package]
edition = "2024"
rust-version = "1.86"
name = "luna-jit"
version = "2.16.0"
authors = ["GOLIA K.K. <lihao@golia.jp>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A Lua runtime in pure Rust — full 5.1/5.2/5.3/5.4/5.5 support. Equivalent to `luna-core` plus a Cranelift-backed JIT (method + trace) and the lua.h-compatible C ABI. (The `luna` crate name on crates.io is taken by an unrelated utility library; this crate is the JIT-equipped variant of the goliajp/luna Lua runtime.)"
readme = "README.md"
keywords = [
"lua",
"vm",
"interpreter",
"jit",
"embedded",
]
categories = [
"compilers",
"no-std",
]
license = "MIT OR Apache-2.0"
repository = "https://github.com/goliajp/luna"
resolver = "2"
[features]
llvm-jit = ["dep:luna-jit-llvm"]
repl-line-editor = ["dep:rustyline"]
send = ["luna-core/send"]
[lib]
name = "luna_jit"
crate-type = [
"rlib",
"cdylib",
"staticlib",
]
path = "src/lib.rs"
[[bin]]
name = "luna"
path = "src/bin/luna.rs"
[[example]]
name = "async_host"
path = "examples/async_host.rs"
[[example]]
name = "bench_1k_h_dict_5k"
path = "examples/bench_1k_h_dict_5k.rs"
[[example]]
name = "bench_1k_h_fib28"
path = "examples/bench_1k_h_fib28.rs"
[[example]]
name = "bench_a4_prime_token_bucket"
path = "examples/bench_a4_prime_token_bucket.rs"
[[example]]
name = "check_token_bucket_value"
path = "examples/check_token_bucket_value.rs"
[[example]]
name = "diag_fib28_self_rec"
path = "examples/diag_fib28_self_rec.rs"
[[example]]
name = "diag_fib28_wallclock_refresh"
path = "examples/diag_fib28_wallclock_refresh.rs"
[[example]]
name = "diag_opcode_breakdown"
path = "examples/diag_opcode_breakdown.rs"
[[example]]
name = "diag_opcode_breakdown_interp"
path = "examples/diag_opcode_breakdown_interp.rs"
[[example]]
name = "diag_polish6_inline_fire"
path = "examples/diag_polish6_inline_fire.rs"
[[example]]
name = "diag_r3c_downrec_dispatch"
path = "examples/diag_r3c_downrec_dispatch.rs"
[[example]]
name = "diag_r3d_fib3_gain"
path = "examples/diag_r3d_fib3_gain.rs"
[[example]]
name = "diag_token_bucket"
path = "examples/diag_token_bucket.rs"
[[example]]
name = "diag_v29_jit_engage"
path = "examples/diag_v29_jit_engage.rs"
[[example]]
name = "embedding_quickstart"
path = "examples/embedding_quickstart.rs"
[[example]]
name = "macro_lua_demo"
path = "examples/macro_lua_demo.rs"
[[example]]
name = "perf_token_bucket_detailed"
path = "examples/perf_token_bucket_detailed.rs"
[[example]]
name = "perf_token_bucket_trace"
path = "examples/perf_token_bucket_trace.rs"
[[example]]
name = "probe_design2_snapshot_walk"
path = "examples/probe_design2_snapshot_walk.rs"
[[example]]
name = "probe_phase_1g_c_fire_count"
path = "examples/probe_phase_1g_c_fire_count.rs"
[[example]]
name = "probe_sub2b_retroactive"
path = "examples/probe_sub2b_retroactive.rs"
[[example]]
name = "repl_lite"
path = "examples/repl_lite.rs"
[[example]]
name = "runone"
path = "examples/runone.rs"
[[example]]
name = "samply_drv_fib28"
path = "examples/samply_drv_fib28.rs"
[[example]]
name = "samply_drv_token_bucket"
path = "examples/samply_drv_token_bucket.rs"
[[example]]
name = "sandbox_demo"
path = "examples/sandbox_demo.rs"
[[example]]
name = "userdata_demo"
path = "examples/userdata_demo.rs"
[[example]]
name = "userdata_redis_stub"
path = "examples/userdata_redis_stub.rs"
[[example]]
name = "userdata_vec3"
path = "examples/userdata_vec3.rs"
[[test]]
name = "ao_pf_counter_smoke"
path = "tests/ao_pf_counter_smoke.rs"
[[test]]
name = "capi"
path = "tests/capi.rs"
[[test]]
name = "cv_send_vm_jit_smoke"
path = "tests/cv_send_vm_jit_smoke.rs"
[[test]]
name = "j_a_send_jit_module_wrapper"
path = "tests/j_a_send_jit_module_wrapper.rs"
[[test]]
name = "j_b_capi_storage_mismatch_no_sigabrt"
path = "tests/j_b_capi_storage_mismatch_no_sigabrt.rs"
[[test]]
name = "j_b_vm_jit_storage_field_migration"
path = "tests/j_b_vm_jit_storage_field_migration.rs"
[[test]]
name = "j_d_scoped_rebind_and_sleeve"
path = "tests/j_d_scoped_rebind_and_sleeve.rs"
[[test]]
name = "jit_dialect_audit"
path = "tests/jit_dialect_audit.rs"
[[test]]
name = "jit_trait_boundary"
path = "tests/jit_trait_boundary.rs"
[[test]]
name = "lua_facade"
path = "tests/lua_facade.rs"
[[test]]
name = "path_d_isle_dse_integration"
path = "tests/path_d_isle_dse_integration.rs"
[[test]]
name = "phase_1i_b_ic_scaffold"
path = "tests/phase_1i_b_ic_scaffold.rs"
[[test]]
name = "phase_1i_b_ic_scaffold_off"
path = "tests/phase_1i_b_ic_scaffold_off.rs"
[[test]]
name = "r1_retf_guards_fib28_p16on"
path = "tests/r1_retf_guards_fib28_p16on.rs"
[[test]]
name = "r2_close_cause_hygiene"
path = "tests/r2_close_cause_hygiene.rs"
[[test]]
name = "r3_3_sub0_selflink_relax"
path = "tests/r3_3_sub0_selflink_relax.rs"
[[test]]
name = "r3_3_sub1_base_var_scaffold"
path = "tests/r3_3_sub1_base_var_scaffold.rs"
[[test]]
name = "r3a_trace_end_downrec_emitted"
path = "tests/r3a_trace_end_downrec_emitted.rs"
[[test]]
name = "r3b_lowerer_stitch_sentinel"
path = "tests/r3b_lowerer_stitch_sentinel.rs"
[[test]]
name = "r3c_dispatcher_stitch_dispatch"
path = "tests/r3c_dispatcher_stitch_dispatch.rs"
[[test]]
name = "r3d_multi_way_guard_dispatch"
path = "tests/r3d_multi_way_guard_dispatch.rs"
[[test]]
name = "sandbox"
path = "tests/sandbox.rs"
[[test]]
name = "trace_jit_audit"
path = "tests/trace_jit_audit.rs"
[[test]]
name = "trace_jit_p15_a_v0"
path = "tests/trace_jit_p15_a_v0.rs"
[[test]]
name = "trace_jit_p15_a_v1"
path = "tests/trace_jit_p15_a_v1.rs"
[[test]]
name = "trace_jit_p15_a_v2_a"
path = "tests/trace_jit_p15_a_v2_a.rs"
[[test]]
name = "trace_jit_p2a_minmax_fold"
path = "tests/trace_jit_p2a_minmax_fold.rs"
[[test]]
name = "trace_jit_s1"
path = "tests/trace_jit_s1.rs"
[[test]]
name = "trace_jit_s10_step_a"
path = "tests/trace_jit_s10_step_a.rs"
[[test]]
name = "trace_jit_s10_step_b"
path = "tests/trace_jit_s10_step_b.rs"
[[test]]
name = "trace_jit_s11_step_a"
path = "tests/trace_jit_s11_step_a.rs"
[[test]]
name = "trace_jit_s11_step_b"
path = "tests/trace_jit_s11_step_b.rs"
[[test]]
name = "trace_jit_s11_step_b_v2"
path = "tests/trace_jit_s11_step_b_v2.rs"
[[test]]
name = "trace_jit_s12_step_a"
path = "tests/trace_jit_s12_step_a.rs"
[[test]]
name = "trace_jit_s12_step_a_v2"
path = "tests/trace_jit_s12_step_a_v2.rs"
[[test]]
name = "trace_jit_s12_step_a_v3"
path = "tests/trace_jit_s12_step_a_v3.rs"
[[test]]
name = "trace_jit_s12_step_b"
path = "tests/trace_jit_s12_step_b.rs"
[[test]]
name = "trace_jit_s12_step_b_v2"
path = "tests/trace_jit_s12_step_b_v2.rs"
[[test]]
name = "trace_jit_s12_step_b_v3"
path = "tests/trace_jit_s12_step_b_v3.rs"
[[test]]
name = "trace_jit_s12_step_b_v4"
path = "tests/trace_jit_s12_step_b_v4.rs"
[[test]]
name = "trace_jit_s12_step_b_v5"
path = "tests/trace_jit_s12_step_b_v5.rs"
[[test]]
name = "trace_jit_s12_step_c"
path = "tests/trace_jit_s12_step_c.rs"
[[test]]
name = "trace_jit_s12_step_c_v2"
path = "tests/trace_jit_s12_step_c_v2.rs"
[[test]]
name = "trace_jit_s12_step_c_v3"
path = "tests/trace_jit_s12_step_c_v3.rs"
[[test]]
name = "trace_jit_s12_step_d"
path = "tests/trace_jit_s12_step_d.rs"
[[test]]
name = "trace_jit_s2c"
path = "tests/trace_jit_s2c.rs"
[[test]]
name = "trace_jit_s3"
path = "tests/trace_jit_s3.rs"
[[test]]
name = "trace_jit_s4_step0"
path = "tests/trace_jit_s4_step0.rs"
[[test]]
name = "trace_jit_s4_step1"
path = "tests/trace_jit_s4_step1.rs"
[[test]]
name = "trace_jit_s4_step2"
path = "tests/trace_jit_s4_step2.rs"
[[test]]
name = "trace_jit_s4_step2b"
path = "tests/trace_jit_s4_step2b.rs"
[[test]]
name = "trace_jit_s4_step2c"
path = "tests/trace_jit_s4_step2c.rs"
[[test]]
name = "trace_jit_s4_step3b"
path = "tests/trace_jit_s4_step3b.rs"
[[test]]
name = "trace_jit_s4_step4a"
path = "tests/trace_jit_s4_step4a.rs"
[[test]]
name = "trace_jit_s4_step4b"
path = "tests/trace_jit_s4_step4b.rs"
[[test]]
name = "trace_jit_s5_step_a"
path = "tests/trace_jit_s5_step_a.rs"
[[test]]
name = "trace_jit_s5_step_b"
path = "tests/trace_jit_s5_step_b.rs"
[[test]]
name = "trace_jit_s5_step_c"
path = "tests/trace_jit_s5_step_c.rs"
[[test]]
name = "trace_jit_s5_step_d"
path = "tests/trace_jit_s5_step_d.rs"
[[test]]
name = "trace_jit_s6_step_a"
path = "tests/trace_jit_s6_step_a.rs"
[[test]]
name = "trace_jit_s7_step_a"
path = "tests/trace_jit_s7_step_a.rs"
[[test]]
name = "trace_jit_s7_step_c"
path = "tests/trace_jit_s7_step_c.rs"
[[test]]
name = "trace_jit_s8_step_a"
path = "tests/trace_jit_s8_step_a.rs"
[[test]]
name = "trace_jit_s8_step_b"
path = "tests/trace_jit_s8_step_b.rs"
[[test]]
name = "trace_jit_s8_step_c"
path = "tests/trace_jit_s8_step_c.rs"
[[test]]
name = "trace_jit_s9_step_a"
path = "tests/trace_jit_s9_step_a.rs"
[[test]]
name = "trace_jit_s9_step_b"
path = "tests/trace_jit_s9_step_b.rs"
[[test]]
name = "trace_jit_s9_step_c"
path = "tests/trace_jit_s9_step_c.rs"
[[test]]
name = "userdata_derive"
path = "tests/userdata_derive.rs"
[[bench]]
name = "bench_send_overhead"
path = "benches/bench_send_overhead.rs"
harness = false
[[bench]]
name = "cross_dialect"
path = "benches/cross_dialect.rs"
harness = false
[[bench]]
name = "lua_microbench"
path = "benches/lua_microbench.rs"
harness = false
[[bench]]
name = "redis_lua_shape"
path = "benches/redis_lua_shape.rs"
harness = false
[[bench]]
name = "run_only"
path = "benches/run_only.rs"
harness = false
[dependencies.cranelift]
version = "0.124"
[dependencies.cranelift-codegen]
version = "0.124"
[dependencies.cranelift-frontend]
version = "0.124"
[dependencies.cranelift-jit]
version = "0.124"
[dependencies.cranelift-module]
version = "0.124"
[dependencies.cranelift-native]
version = "0.124"
[dependencies.luna-core]
version = "= 2.16.0"
[dependencies.luna-jit-derive]
version = "= 2.16.0"
[dependencies.luna-jit-helpers]
version = "= 2.16.0"
[dependencies.luna-jit-llvm]
version = "= 2.16.0"
optional = true
[dependencies.rustyline]
version = "14"
optional = true
[dev-dependencies.criterion]
version = "0.5"
features = ["cargo_bench_support"]
default-features = false
[lints.clippy]
doc_lazy_continuation = "allow"
doc_overindented_list_items = "allow"
incompatible_msrv = "allow"
missing_safety_doc = "allow"
needless_range_loop = "allow"
too_many_arguments = "allow"
type_complexity = "allow"
[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(luna_aot_runtime_stub)"]