HigherOrderCO / HigherOrderCO/HVM4
Cross-platform embedding of HVM4
- Dominant language
- C
- Stars
- 121
- Forks
- 28
- PR merge metrics
- No merged PRs in 30d
Description
It would be wonderful to make HVM4 compilable as an embedded library on WASM, iOS, Android, and Linux/macOS/Windows by adding minimal `#ifdef` guards to the system abstraction layer. Zero changes to the core evaluation engine.
Made 5 independent PRs/updates to do this, each on its own branch, would be great if you could take a look:
1. [**Configurable HEAP_CAP and MAX_THREADS**](https://github.com/HigherOrderCO/HVM4/pull/49) - Allow tuning for constrained environments (WASM linear memory, mobile address spaces).
2. [**Platform-abstract mmap/munmap**](https://github.com/HigherOrderCO/HVM4/pull/50) - Compile on platforms without POSIX `mmap` (WASM, embedded).
3. [**Guard dlopen/dlsym**](https://github.com/HigherOrderCO/HVM4/pull/52) - Compile on platforms without dynamic linking (WASM, iOS App Store).
4. [**Guard fork/execvp in AOT builder**](https://github.com/HigherOrderCO/HVM4/pull/53) - Compile on sandboxed platforms that prohibit process spawning (WASM, iOS, Android).
5. [**Add lib.c library entry point**](https://github.com/HigherOrderCO/HVM4/pull/51) - Expose HVM4 internals as real linker symbols so external code can call into the runtime.
## Scope
- ~50 lines changed across 5 files, plus 1 new file (`lib.c`)
- All guards default to existing behavior
- All existing tests pass unchanged
- Only the system abstraction layer is touched
- Core evaluation is completely untouched
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.