refactor: Remove AOT as backend - #343
Open
mhovd wants to merge 3 commits into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #343 +/- ##
==========================================
+ Coverage 83.82% 84.05% +0.23%
==========================================
Files 82 78 -4
Lines 33983 32536 -1447
==========================================
- Hits 28486 27348 -1138
+ Misses 5497 5188 -309
🚀 New features to boost your workflow:
|
Contributor
There was a problem hiding this comment.
Pull request overview
This PR removes the native ahead-of-time (AoT) DSL backend from pharmsol, consolidating the runtime compilation surface around the in-process JIT workflow and deleting the associated AoT build/export/load implementation and test matrix.
Changes:
- Removed AoT features (
dsl-aot,dsl-aot-load), AoT dependencies, and AoT-related modules (aot, compiled ABI glue, rust backend emitter, build support). - Simplified runtime APIs, tests, and benchmarks to only exercise
RuntimeCompilationTarget::Jit/RuntimeBackend::Jit. - Updated docs and CI configuration to reflect the JIT-only runtime target surface.
Reviewed changes
Copilot reviewed 21 out of 22 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tests/support/runtime_corpus.rs | Drops AoT workspace + AoT compilation helpers; gates support on dsl-jit only. |
| tests/support/bimodal_ke.rs | Removes AoT compilation helpers and workspace; narrows runtime helpers to dsl-jit. |
| tests/runtime_backend_matrix.rs | Removes AoT rows from the backend matrix tests; now JIT-only. |
| tests/full_feature_dsl_backend_parity.rs | Removes JIT↔AoT parity assertions; now validates JIT vs reference only. |
| tests/bimodal_ke_entrypoint_matrix.rs | Removes AoT entrypoints from the test matrix; now JIT-only. |
| src/simulator/equation/ode/mod.rs | Narrows closure_helpers exposure to dsl-jit only. |
| src/parameters.rs | Narrows runtime-model parameter ordering impls/imports to dsl-jit only. |
| src/lib.rs | Removes AoT feature documentation and the build_support module hook. |
| src/dsl/rust_backend.rs | Deletes the Rust source emitter used for AoT artifacts. |
| src/dsl/runtime.rs | Removes AoT targets/artifact loading from runtime surface; updates unit tests accordingly. |
| src/dsl/native.rs | Removes native library-backed artifact ownership and NativeAot backend variant. |
| src/dsl/mod.rs | Removes AoT modules/exports and re-exports; narrows runtime/native modules to dsl-jit. |
| src/dsl/compiled_backend_abi.rs | Deletes the ABI constants/JSON envelope logic used for AoT artifacts. |
| src/dsl/aot.rs | Deletes AoT compile/export/load implementation and associated tests. |
| src/build_support.rs | Deletes the cargo/rustup build scaffolding used by AoT compilation. |
| README.md | Updates DSL/runtime documentation to describe only the JIT workflow. |
| pharmsol-dsl/src/lib.rs | Updates crate docs to reflect execution being JIT-consumed (no AoT backend). |
| pharmsol-dsl/README.md | Removes AoT workflow mentions from the DSL crate README. |
| Cargo.toml | Removes AoT features/deps; updates bench required-features to dsl-jit only. |
| benches/dsl_matrix.rs | Removes AoT backend from the benchmark matrix and related workspace handling. |
| .gitignore | Removes ignores for .pkm artifacts and a removed tests/browser-e2e/node_modules/ path. |
| .github/workflows/build.yml | Removes AoT smoke-target install/env wiring; keeps test matrix otherwise. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
643
to
+648
| let jit_values = subject_values( | ||
| &jit.estimate_predictions(&subject, &support) | ||
| .expect("jit predictions"), | ||
| ); | ||
| let aot_values = subject_values( | ||
| &aot.estimate_predictions(&subject, &support) | ||
| .expect("aot predictions"), | ||
| ); | ||
|
|
||
| for (jit_value, aot_value) in jit_values.iter().zip(aot_values.iter()) { | ||
| assert_relative_eq!(jit_value, aot_value, max_relative = 1e-4); | ||
| } | ||
| assert_eq!(jit_values.len(), 6); | ||
| assert!(jit_values.iter().all(|value| value.is_finite())); |
Contributor
|
| Project | pharmsol |
| Branch | remove-aot |
| Testbed | mhovd-pgx |
⚠️ WARNING: Truncated view!The full continuous benchmarking report exceeds the maximum length allowed on this platform.
🚨 3 Alerts
🐰 View full continuous benchmarking report in Bencher
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.
Most users will just compile their binary with pharmsol as a dependency, instead of using this AOT