Releases: ProjectTorreyPines/AdaptiveArrayPools.jl
v0.3.6
Bug Fix
Type-stable task-local pool accessors (CPU/CUDA/Metal)
get_task_local_*_pool() accessors (CPU/CUDA/Metal) now return fully concrete parametric types, fixing type instability.
What's Changed
- (fix): Type-stable task-local pool accessors for CPU/CUDA/Metal by @mgyoo86
Full Changelog: v0.3.5...v0.3.6
v0.3.5
Bug Fix
Julia 1.11 falls back to legacy N-way cache path (#41)
Julia 1.11 has a bug where length(::Array) can disagree with prod(size(...)) after setfield!(:ref) reuse, breaking vec() and reshape(). Julia 1.11 now uses the legacy N-way cache path (zero-alloc on cache hit). The modern setfield! path and GPU extensions (CUDA, Metal) are gated at Julia 1.12+.
What's Changed
Full Changelog: v0.3.4...v0.3.5
v0.3.4
What's New
Zero-Alloc Others Overlap Check
RUNTIME_CHECK=1 others-type overlap check is now zero-allocation, matching the fixed-slot fast path from v0.3.3.
acquire_view! Escape Detection
Fixes a false-negative where acquire_view! for non-fixed-slot types was not recording pointer bounds, so views could bypass the overlap check. Also fixes scope boundary handling and adds missing legacy (Julia ≤1.10) definitions.
What's Changed
Full Changelog: v0.3.3...v0.3.4
v0.3.3
What's New
Zero-Allocation RUNTIME_CHECK=1 Hot Path (#37)
RUNTIME_CHECK=1 (runtime escape detection) no longer allocates in the acquire/rewind hot path. Fully zero-alloc after warmup.
Improved Compile-Time Escape Detection (#38)
Rewrites the compile-time escape detector with order-aware taint tracking. Fixes false negatives (missed escapes when variables were reassigned before acquire!) and false positives (incorrect errors from inner-scope shadowing and reassigned containers). Adds a new PoolReassignEscapeWarning for ambiguous v = f(v) patterns. CUDA/Metal block forms now have full warning parity with CPU.
What's Changed
- (perf): zero-allocation RUNTIME_CHECK=1 hot path by @mgyoo86 in #37
- (feat): Order-aware compile-time escape detection by @mgyoo86 in #38
Full Changelog: v0.3.2...v0.3.3
v0.3.2
Scope-Aware Runtime Escape Detection
Scope-Aware Validation (CPU, CUDA, Metal)
Runtime escape detection (RUNTIME_CHECK=1) no longer false-positives on arrays from outer @with_pool scopes used inside nested inner scopes. Leaked inner scopes (caught exceptions) are now cleaned up before validation.
Robust Poisoning for Custom Types
_poison_fill! now handles custom isbits structs (duck-type 0 * first(v) fallback) and skips non-isbits reference types gracefully.
What's Changed
Full Changelog: v0.3.1...v0.3.2
v0.3.1
What's New
Metal.jl Support (#34)
Full Apple Silicon GPU backend — same API as CUDA (@with_pool :metal), lazy/typed-lazy modes, full safety suite, and task-local multi-device pools. Requires Julia 1.11+. See 📖 Metal Backend.
Structural Mutation Detection (#35)
Catches resize!/push!/append! on pool-backed arrays:
- Compile-time:
PoolMutationErrorat macro expansion (zero cost) - Runtime: wrapper-vs-backing divergence check at rewind — advisory
@warnwithmaxlog=1(pool self-heals on nextacquire!)
Works across CPU, CUDA, and Metal. See 📖 Pool Safety.
Other
- CUDA extension now gated behind Julia 1.11+ to match Metal
What's Changed
- (feat): Metal.jl (Apple Silicon GPU) backend support by @mgyoo86 in #34
- (feat): compile-time and runtime structural mutation detection by @mgyoo86 in #35
Full Changelog: v0.3.0...v0.3.1
v0.3.0
⚠️ Breaking Changes
Default acquire! returns Array
acquire!now returnsArray{T,N}instead ofSubArray/ReshapedArray. On Julia 1.11+,Arrayis a mutable struct enabling zero-allocationsetfield!reuse — the same guarantee views had, with better FFI/ccall and type constraint compatibility.- New
acquire_view!provides explicit opt-in to the old view behavior.
Remove unsafe_* API
- The entire
unsafe_*API (unsafe_acquire!,unsafe_zeros!,unsafe_ones!,unsafe_similar!) is removed with no deprecation period.
Migration Guide
unsafe_acquire! → acquire!
unsafe_zeros! → zeros!
unsafe_ones! → ones!
unsafe_similar! → similar!
If you relied on acquire! returning views: acquire! → acquire_view!
See the full 📖 Migration Guide for details.
What's Changed
Full Changelog: v0.2.6...v0.3.0
v0.2.6
Eliminate try-finally Overhead in @with_pool
@with_pool now uses direct rewind insertion instead of try-finally, enabling compiler inlining for ~15-25% speedup on hot-loop patterns.
New @safe_with_pool / @safe_maybe_with_pool macros preserve the old try-finally behavior for code that needs guaranteed exception cleanup.
What's Changed
Full Changelog: v0.2.5...v0.2.6
v0.2.5
Fix Compile-Time Explosion in Nested @with_pool
Nested or @inline @with_pool could cause compile-time explosion due to exponential macro expansion. Fixed by replacing union splitting with a single compile-time type assertion.
Safety system simplified from 4-tier (0–3) to binary RUNTIME_CHECK (0=off, 1=on) via LocalPreferences.toml. POOL_DEBUG, POOL_SAFETY_LV, set_safety_level! are removed.
See 📖 Safety and 📖 Configuration docs for details.
What's Changed
Full Changelog: v0.2.4...v0.2.5
v0.2.4
Hotfix: Eliminate Core.Box Allocation in @inline @with_pool
v0.2.3 introduced a Core.Box boxing regression (32–48 bytes) in @inline @with_pool functions, caused by closure-based dispatch interacting with try/finally boundaries after inlining.
Replaced with closureless union splitting on both CPU and CUDA — zero allocation on Julia 1.12+. On Julia <1.12, a minor 16-byte let-scope overhead may appear at top-level but disappears inside functions and hot loops.
What's Changed
Full Changelog: v0.2.3...v0.2.4