Repository navigation
feat(toolchain): harden inputs and add integer lowering and interpreted calls - #293
Merged
LunaStev merged 8 commits intoOct 12, 2026
Merged
Conversation
Batch 1: fixes wavefnd#132, wavefnd#133, wavefnd#134, wavefnd#135, wavefnd#137, and wavefnd#138. Signed-off-by: LunaStev <[email protected]>
…ures Signed-off-by: LunaStev <[email protected]>
Batch 3: fixes wavefnd#33, wavefnd#34, and wavefnd#42. Signed-off-by: LunaStev <[email protected]>
…ocation work Add fallible IR construction, safe type-layout overrides, bounded direct AST lowering/encoding with iterative rejection disposal, complete ELF output preflight, and shared object validation at symbol resolution. Fixes wavefnd#55 Fixes wavefnd#244 Fixes wavefnd#245 Fixes wavefnd#246 Fixes wavefnd#247 Signed-off-by: LunaStev <[email protected]>
Signed-off-by: LunaStev <[email protected]>
Add Bool-only logical expressions with preserved RHS control flow and phi results, integer bitwise/not, division/remainder and signedness-aware shifts. Preserve and validate the corresponding constant trees and evaluate logical constant expressions lazily with defined integer trap/wrap/count semantics. Write AST format 3 and typed IR format 5, gate the new syntax by version, and retain compatibility with AST 2 and typed IR 3/4 inputs. Bound AST nesting to 32 levels so accepted trees also roundtrip through the JSON recursion limit. Fixes wavefnd#151 Fixes wavefnd#152 Fixes wavefnd#153 Fixes wavefnd#154 Signed-off-by: LunaStev <[email protected]>
Batch 7: fixes wavefnd#40, wavefnd#127, wavefnd#92, wavefnd#195, wavefnd#196, wavefnd#197, wavefnd#275, wavefnd#276, and wavefnd#280. Signed-off-by: LunaStev <[email protected]>
Execute defined Whale calls with private invocation environments and shared fuel, stack-memory, depth, frame and live-value budgets. Preserve module-local typed callable identity and data-pointer capabilities across calls, returns, storage and split byte copies; reject unsupported reachable callees before effects and raw callable authority at dispatch. Refs wavefnd#254, wavefnd#255, wavefnd#256, wavefnd#257 Signed-off-by: LunaStev <[email protected]>
LunaStev
force-pushed
the
feat/toolchain-correctness-and-execution
branch
from
October 12, 2026 07:29
df2cdbb to
a393c65
Compare
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Malformed assembly could be accepted, public Rust inputs could abort before resource checks, and valid IR calls could not execute. This series rejects malformed input with preserved artifacts, bounds public construction/serialization work, expands integer frontend and AMD64 instruction support, and executes direct/indirect Whale calls with tracked pointer identity and shared limits.
The requested delivery is one PR containing exactly eight signed commits covering 40 issues, in the following order. Each batch has focused regressions; the final combined tree is tested in both feature configurations, at MSRV, and in release mode.
00a51954c5557db5d0eb1aae8209bf712f15061bdee0d0a61a393c65Motivation and resulting behavior
Target and compatibility impact
AstLimitsdefaults to a safe 32-level nesting ceiling; oversized owned ASTs are disposed iteratively. Assembly output defaults to 64 MiB; CLI input defaults are 8 MiB for assembly and 256 MiB for raw objects, configurable with--max-input N.IrLimitsadds a shared 16,777,216-unit analysis budget.InterpreterOptionsadds call depth (256), total frame (100,000) and simultaneously reserved SSA-slot (1,000,000) limits. Explicit struct initializers may need the new fields or..Default::default().Validation
Final head
a393c65cd48689e5a36e0fa301ea3050174ad5e7, Linux x86_64, Rust 1.96.0 and MSRV 1.86.0. Cargo used--locked --offline, separate target directories andCARGO_INCREMENTAL=0for final checks.cargo test --workspace --locked --offline: 248 passed.cargo test --workspace --all-features --locked --offline: 303 passed.cargo +1.86.0 test --workspace --all-features --locked --offline: 303 passed.cargo test --workspace --all-features --release --locked --offline: 303 passed.cargo clippy --all-targets [--all-features] --locked --offline -- -D warnings: both configurations passed.tools/ci_smoke.py: passed sequentially.python3 -m unittest discover -s tools -p 'test_*.py': 15 passed; bootstrap tests use fake build stages and require no Wave/LLVM installation.RUSTDOCFLAGS='-D warnings' cargo doc --workspace --all-features --no-deps --locked --offline,cargo fmt --all -- --check,git diff --check: passed.Windows/macOS/emulated host checks, coverage and the optional Wave-record bootstrap were not rerun locally; the registered CI workflows handle those paths. Initial CI passed all 19 non-macOS checks; four macOS checks identified APFS rejection of the raw-byte test filename. Batch 2 now accommodates that fixture-creation failure while still exercising every CLI rejection and preservation assertion. The focused CLI suite (5 tests), Clippy and formatting passed after this test-only correction. All 23 GitHub CI checks now pass at the head above, including native Linux/macOS/Windows on x64 and ARM64, MSRV, release regressions, coverage, RISC-V/QEMU and Wave ELF smoke. Normal tests require no external assembler. Temporary build-artifact quota exhaustion during final preparation was resolved by removing this task's generated build directories; all final checks above subsequently passed.
CI run: all 23 checks passed.
Linked issues
Batch 1: Closes #132, Closes #133, Closes #134, Closes #135, Closes #137, Closes #138.
Batch 2: Closes #15, Closes #139, Closes #248, Closes #249, Closes #250.
Batch 3: Closes #33, Closes #34, Closes #42.
Batch 4: Closes #55, Closes #244, Closes #245, Closes #246, Closes #247.
Batch 5: Closes #251, Closes #252, Closes #253, Closes #288.
Batch 6: Closes #151, Closes #152, Closes #153, Closes #154.
Batch 7: Closes #40, Closes #127, Closes #92, Closes #195, Closes #196, Closes #197, Closes #275, Closes #276, Closes #280.
Batch 8: Closes #254, Closes #255, Closes #256, Closes #257.
Checklist
Signed-off-by.