# higherorderco/hvm2

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/higherorderco-hvm2).**

11,290 stars · 435 forks · Cuda · Apache-2.0

## Links

- GitHub: https://github.com/HigherOrderCO/HVM2
- Homepage: https://higherorderco.com
- awesome-repositories: https://awesome-repositories.com/repository/higherorderco-hvm2.md

## Description

HVM2 is a high-performance execution environment for pure functional programs, implemented as a systems-level runtime in Rust. It functions as a massively parallel functional runtime that uses interaction combinators to achieve automatic parallelism across multi-core CPUs and GPUs.

The project distinguishes itself by using a graph-rewriting computational model to execute programs via local reduction rules, which eliminates the need for manual locks or atomic operations. It employs beta-optimal reduction and lazy evaluation to optimize higher-order functions and eliminate redundant computation steps at runtime.

The runtime features a garbage-free memory management system that reclaims unreachable data instantly through linear interaction nets. Its capability surface includes the ability to compile high-level languages into interaction nets and a parallel evaluator used for the verification of formal mathematical proofs.

The execution environment utilizes a work-stealing task scheduler to distribute independent computations across available hardware threads.

## Tags

### Programming Languages & Runtimes

- [Garbage-Free Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/garbage-free-runtimes.md) — Implements a garbage-free runtime that reclaims memory instantly via linear interaction nets. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Interaction Combinator Graph Rewriting](https://awesome-repositories.com/f/programming-languages-runtimes/interaction-combinator-graph-rewriting.md) — Uses a graph-rewriting model based on interaction combinators to enable lock-free parallel execution across thousands of threads.
- [Interaction Net Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/language-features-paradigms/concurrency-models/concurrency/execution-models/multi-threaded-execution/interaction-net-runtimes.md) — Uses a graph-based interaction net model to achieve optimal reduction and automatic parallelism without relying on a garbage collector. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Pure Functional Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/pure-functional-runtimes.md) — Implements a high-performance execution environment for pure functional programs using interaction combinators and lazy evaluation.
- [Beta-Optimal Reduction Engines](https://awesome-repositories.com/f/programming-languages-runtimes/beta-optimal-reduction-engines.md) — Eliminates redundant computation steps at runtime through beta-optimality to perform automatic fusion and deforestation. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Beta-Optimal Reductions](https://awesome-repositories.com/f/programming-languages-runtimes/beta-optimal-reductions.md) — Implements beta-optimal reduction to eliminate redundant computation steps in higher-order functions.
- [Lazy Evaluation](https://awesome-repositories.com/f/programming-languages-runtimes/deferred-execution/lazy-evaluation.md) — Defers the computation of expressions until results are required to eliminate redundant higher-order function calls.
- [Garbage-Free Memory Management](https://awesome-repositories.com/f/programming-languages-runtimes/garbage-free-memory-management.md) — Reclaims memory instantly as data becomes unreachable using a linear interaction-net model to avoid collection pauses. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Function Execution Models](https://awesome-repositories.com/f/programming-languages-runtimes/generator-functions/function-execution-models.md) — Runs lazy functional code using a beta-optimal model of computation to achieve high efficiency. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Heterogeneous Hardware Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/heterogeneous-hardware-runtimes.md) — Executes a single program across GPU and CPU cores simultaneously to achieve speedup without manual threading. ([source](https://higherorderco.com))
- [Reduction Optimizations](https://awesome-repositories.com/f/programming-languages-runtimes/higher-order-function-implementation/reduction-optimizations.md) — Executes complex functional patterns faster by applying beta-optimal reductions during runtime. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Linear Memory Management](https://awesome-repositories.com/f/programming-languages-runtimes/linear-memory-management.md) — Reclaims unreachable data instantly through the structural properties of linear interaction nets. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Manual Memory Reclamation](https://awesome-repositories.com/f/programming-languages-runtimes/manual-memory-reclamation.md) — Frees unreachable data instantly as it becomes unused to avoid stop-the-world collection pauses. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Parallel Computing Implementation](https://awesome-repositories.com/f/programming-languages-runtimes/parallel-computing-implementation.md) — Distributes independent sub-expressions across CPU cores using a work-stealing queue to maximize throughput. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Parallel Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/parallel-runtimes.md) — Provides a high-performance execution environment that automatically distributes computational tasks across CPU and GPU threads. ([source](https://higherorderco.com))
- [Parallel Function Execution](https://awesome-repositories.com/f/programming-languages-runtimes/programming-utilities/functional/objective-function-execution/parallel-function-execution.md) — Runs pure functional code across multiple CPU cores automatically by exploiting implicit parallelism via a work-stealing queue. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Automatic Functional Parallelism](https://awesome-repositories.com/f/programming-languages-runtimes/programming-utilities/functional/objective-function-execution/parallel-function-execution/automatic-functional-parallelism.md) — Automatically executes pure functional code across multi-core CPUs and GPUs without manual locks.
- [Lock-Free Parallel Execution](https://awesome-repositories.com/f/programming-languages-runtimes/programming-utilities/functional/objective-function-execution/parallel-function-execution/lock-free-parallel-execution.md) — Executes code across multi-core CPUs and GPUs without the need for manual locks or atomic operations. ([source](https://higherorderco.com))
- [Pure Functions](https://awesome-repositories.com/f/programming-languages-runtimes/pure-functions.md) — Runs functional code using a lazy evaluation model that eliminates redundant computations for higher-order functions. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Execution Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/pure-functions/execution-runtimes.md) — Provides a high-performance runtime for executing pure functional programs using lazy evaluation.
- [Lazy Evaluation Engines](https://awesome-repositories.com/f/programming-languages-runtimes/runtime-execution-environments/runtime-environments/runtimes/graph-symbolic-execution-engines/lazy-evaluation-engines.md) — Computes only necessary operations for final output through a lazy evaluation engine.
- [Rust Runtime Accelerations](https://awesome-repositories.com/f/programming-languages-runtimes/rust-runtime-accelerations.md) — Uses a systems-level Rust implementation to provide a high-performance, massively parallel runtime for functional programs.
- [Stop-The-World Pauses](https://awesome-repositories.com/f/programming-languages-runtimes/stop-the-world-pauses.md) — Eliminates stop-the-world pauses by utilizing linear interaction nets for instant memory reclamation. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Combinator-Based Scaling](https://awesome-repositories.com/f/programming-languages-runtimes/combinator-based-scaling.md) — Distributes complex computational workloads across thousands of threads using a model based on interaction combinators.
- [Evaluation Fusion](https://awesome-repositories.com/f/programming-languages-runtimes/deferred-execution/lazy-evaluation/evaluation-fusion.md) — Merges composed function calls into single passes during lazy evaluation to remove redundant processing.
- [Functional Programming Libraries](https://awesome-repositories.com/f/programming-languages-runtimes/functional-programming-libraries.md) — Provides a runtime environment that implements core functional programming primitives and abstractions.
- [Hardware-Agnostic Parallelism](https://awesome-repositories.com/f/programming-languages-runtimes/hardware-agnostic-parallelism.md) — Automatically maps interaction rules to CPU cores and GPU threads for scalable performance across diverse hardware.
- [High-Performance Runtimes](https://awesome-repositories.com/f/programming-languages-runtimes/high-performance-runtimes.md) — Provides a high-performance execution engine optimized for throughput via beta-optimal reductions.
- [Beta-Optimal Reductions](https://awesome-repositories.com/f/programming-languages-runtimes/higher-order-function-implementation/beta-optimal-reductions.md) — Optimizes higher-order functions by eliminating redundant computation steps through beta-optimal reductions.
- [Runtime Fusions](https://awesome-repositories.com/f/programming-languages-runtimes/higher-order-function-implementation/runtime-fusions.md) — Merges sequential function calls into a single pass during execution to reduce redundant processing. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Manual Memory Management](https://awesome-repositories.com/f/programming-languages-runtimes/manual-memory-management.md) — Implements an explicit memory management system that avoids the unpredictability of garbage collection.
- [Parallel Runtime Compilation](https://awesome-repositories.com/f/programming-languages-runtimes/source-code-compilers/c-source-translators/binary-to-c-translation/high-level-source-transpilation/parallel-runtime-compilation.md) — Transforms high-level code into interaction nets for automatic distribution across multiple processor cores. ([source](https://higherorderco.com))

### Operating Systems & Systems Programming

- [Linear Interaction Memory](https://awesome-repositories.com/f/operating-systems-systems-programming/kernel-core-internals/process-and-memory-management/memory-management/allocation-strategies/dynamic-memory-allocation/custom-memory-allocators/linear-memory-managers/linear-interaction-memory.md) — Reclaims unreachable data instantly through the structural properties of interaction nets to eliminate garbage collection pauses.
- [Managed Memory Allocators](https://awesome-repositories.com/f/operating-systems-systems-programming/kernel-core-internals/process-and-memory-management/memory-management/allocation-strategies/dynamic-memory-allocation/custom-memory-allocators/managed-memory-allocators.md) — Uses a structural model of computation to manage memory allocation and eliminate the need for a garbage collector. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Linear Memory Allocators](https://awesome-repositories.com/f/operating-systems-systems-programming/kernel-core-internals/process-and-memory-management/memory-management/automated-reclamation-systems/garbage-collection/linear-memory-allocators.md) — Ships a memory allocator that reclaims unreachable data through linear interaction nets.
- [Linear Reclamation Systems](https://awesome-repositories.com/f/operating-systems-systems-programming/kernel-core-internals/process-and-memory-management/memory-management/automated-reclamation-systems/garbage-collection/linear-reclamation-systems.md) — Reclaims unreachable data instantly through linear interaction nets to avoid garbage collection pauses.
- [Manual Memory Management](https://awesome-repositories.com/f/operating-systems-systems-programming/manual-memory-management.md) — Implements explicit control over memory allocation and deallocation to ensure predictable performance without garbage collection pauses. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Work-Stealing Schedulers](https://awesome-repositories.com/f/operating-systems-systems-programming/kernel-core-internals/process-and-memory-management/runtime-schedulers/work-stealing-schedulers.md) — Uses a work-stealing scheduler to distribute independent redexes across CPU and GPU threads for balanced workloads.
- [Multi-Core Workload Distribution](https://awesome-repositories.com/f/operating-systems-systems-programming/multi-core-workload-distribution.md) — Partitions functional workloads across multiple physical processor cores using a work-stealing scheduler.
- [Rust Systems Programming](https://awesome-repositories.com/f/operating-systems-systems-programming/rust-systems-programming.md) — Implemented as a systems-level runtime in Rust to leverage zero-cost abstractions and fine-grained memory control.

### Scientific & Mathematical Computing

- [Interaction Net Engines](https://awesome-repositories.com/f/scientific-mathematical-computing/data-modeling-processing/computational-graphs/graph-based-computational-execution/interaction-net-engines.md) — Uses a graph-rewriting engine to execute programs via local reduction rules.
- [High-Performance and Parallel Computing](https://awesome-repositories.com/f/scientific-mathematical-computing/high-performance-execution-environments/high-performance-and-parallel-computing.md) — Provides a high-performance environment that executes computationally intensive functional programs across parallel CPU and GPU resources. ([source](https://higherorderco.com))
- [MPI-Based Parallel Program Executions](https://awesome-repositories.com/f/scientific-mathematical-computing/high-performance-execution-environments/high-performance-and-parallel-computing/mpi-based-parallel-program-executions.md) — Automatically distributes high-level code execution across multi-core CPUs and GPUs to achieve massive parallelism. ([source](https://higherorderco.com))
- [Graph-Based Execution Engines](https://awesome-repositories.com/f/scientific-mathematical-computing/high-performance-execution-environments/scientific-computing-platforms/graph-based-execution-engines.md) — Uses a graph-based execution engine to distribute functional programs across multiple cores without locks.
- [Near-Linear Scaling Distributions](https://awesome-repositories.com/f/scientific-mathematical-computing/distributed-tensor-contractions/near-linear-scaling-distributions.md) — Achieves near-ideal speedup by distributing workloads across available hardware threads using a concurrent interaction model. ([source](https://higherorderco.com))
- [Formal Mathematical Proofs](https://awesome-repositories.com/f/scientific-mathematical-computing/formal-mathematical-proofs.md) — Distributes the verification of formal mathematical proofs across all available processor cores using a parallel evaluator. ([source](https://higherorderco.com))
- [Parallel Verifiers](https://awesome-repositories.com/f/scientific-mathematical-computing/formal-mathematical-proofs/parallel-verifiers.md) — Ships a parallel evaluator used to accelerate the checking of formal mathematical proofs by distributing work across available cores.
- [Parallel Proof Evaluators](https://awesome-repositories.com/f/scientific-mathematical-computing/parallel-proof-evaluators.md) — Accelerates the checking of formal mathematical proofs by distributing verification across all available cores.

### Software Engineering & Architecture

- [Pure Expression Execution](https://awesome-repositories.com/f/software-engineering-architecture/pure-expression-execution.md) — Runs side-effect-free code deterministically, enabling aggressive structural optimizations and safe parallel distribution.
- [System Interaction Modeling](https://awesome-repositories.com/f/software-engineering-architecture/system-interaction-modeling.md) — Implements a computational model where nodes rewrite themselves through local rules to achieve massive parallelism.
- [Runtime Fusions](https://awesome-repositories.com/f/software-engineering-architecture/modular-program-composition/function-composition/runtime-fusions.md) — Combines nested function applications during evaluation to remove unnecessary intermediate data structures without requiring compile-time changes. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))
- [Redex Work-Stealing](https://awesome-repositories.com/f/software-engineering-architecture/task-queues/work-stealing-queues/redex-work-stealing.md) — Distributes the computation of expressions across a pool of threads using a work-stealing queue to maximize hardware utilization. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))

### Web Development

- [Computational Parallelization](https://awesome-repositories.com/f/web-development/performance-optimizations/computational-parallelization.md) — Distributes workloads across multiple processor cores automatically by organizing tasks into a network of interacting operations. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))

### Development Tools & Productivity

- [Redex Reduction Parallelization](https://awesome-repositories.com/f/development-tools-productivity/parallel-execution/parallel-reductions/redex-reduction-parallelization.md) — Distributes expression processing across multiple threads using a work-stealing queue to increase throughput. ([source](https://cdn.jsdelivr.net/gh/higherorderco/hvm2@main/README.md))

### DevOps & Infrastructure

- [Heterogeneous Task Scheduling](https://awesome-repositories.com/f/devops-infrastructure/automation-orchestration/task-execution-frameworks/task-job-management/task-schedulers/os-scheduling-simulations/task-schedulers/heterogeneous-task-scheduling.md) — Distributes interaction rules to CPU and GPU threads automatically to scale performance across thousands of parallel workers.
- [Compute Throughput Optimizers](https://awesome-repositories.com/f/devops-infrastructure/performance-optimization-utilities/compute-throughput-optimizers.md) — Maximizes hardware utilization and computational speed using a concurrent model based on interaction combinators. ([source](https://higherorderco.com))

### User Interface & Experience

- [Parallel](https://awesome-repositories.com/f/user-interface-experience/layout-utilities/presentation-engines/template-engines/control-flow-directives/expression-evaluators/functional-evaluators/parallel.md) — Distributes functional computations across CPU and GPU cores without requiring manual locks.
