Repository navigation
RustyGo v0.3.0 - SSA Lifetime Analysis Foundation
RustyGo v0.3.0
This release introduces the compiler analysis foundation required for safe automatic arena allocation.
Highlights
New SSA-based Analysis Pipeline
RustyGo now analyzes Go programs through SSA instead of source-level AST inspection.
The new pipeline provides a compiler-grade representation for:
- allocation tracking
- ownership propagation
- lifetime verification
- escape detection
Rust-style Lifetime Checker
Added a lifetime analysis engine inspired by Rust's ownership model.
Features:
- region tracking
- ownership graphs
- alias propagation
- lifetime validation
- escape diagnostics
The analyzer can now determine whether an allocation can safely remain within its owning scope.
Allocation Discovery
RustyGo now discovers allocation candidates from SSA:
- heap allocations
- slices
- maps
- channels
- pointer-producing instructions
Each allocation receives a unique identity and analysis metadata.
Escape Classification
Added a classification layer that converts lifetime results into allocation decisions:
- Arena
- Heap
- Unknown
RustyGo follows a strict safety rule:
Unknown is never treated as safe.
Improved Analysis Diagnostics
Reports now include:
- allocation location
- lifetime state
- escape reason
- propagation path
Example:
Allocation #12
Type:
*Request
Decision:
Heap
Reason:
EscapesReturn
Path:
Alloc → Variable → Return
Architecture Progress
Current pipeline:
Go Source
|
v
SSA
|
v
Allocation Discovery
|
v
Lifetime Checker
|
v
Escape Classification
|
v
Arena Rewrite (planned)
Roadmap
Completed:
- Arena allocator
- SSA analysis
- Ownership analysis
- Region tracking
- Lifetime checker
- Allocation discovery
- Escape classification
Next:
- Function summaries
- Arena rewrite pass
- Compiler integration improvements
- Automatic allocation replacement
Breaking Changes
None.
This release adds compiler analysis capabilities without changing the public runtime API.