You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Part of the 200+ optimization campaign. Two clusters:
CLEANUP (16 mods):
- Remove unused imports in evolution.rs (GateId, HashMap,
RandomState, BuildHasher, Hasher) and hbit.rs (HInt)
- Underscore-prefix unused gate_map params in optimizer.rs
- Remove orphaned doc comment that wasn't attached to any item
- Rename pyo3 _bound deprecations: import/eval/run/PyList::empty/
PyDict::new/PyTuple::new
- Fix CString to as_c_str() for new pyo3 0.23 eval/run signatures
- Fix PyTuple::new -> Result; remove redundant Ok wrap
- Add #[allow(deprecated)] for the 2 remaining IntoPy::into_py
warnings (full IntoPyObject migration is its own task)
PERF (24 mods, all #[inline] annotations + 1 fast-path):
- phi_pi_fib::nearest_attractor_with_dist: small-value fast-path
(skip binary search for |v| <= 3, which are themselves attractors).
Common in OMC hot loops (counters, small indices).
- phi_pi_fib::{nearest_attractor_with_dist, fold_to_nearest_attractor,
is_on_fibonacci_attractor}: #[inline]
- HInt::{new, compute_resonance, compute_him, singularity}: #[inline].
Called in every harmonic int op.
- HArray::{from_vec, len, is_empty}: #[inline]
- Value::{dict_from, dict_empty, to_int, to_float, to_bool, is_float,
is_numeric, is_singularity}: #[inline]
- 5 NEW Value::is_* helpers (is_int, is_string, is_array, is_dict,
is_null) — currently dispatchers use matches!() inline; these
expose the same checks with consistent naming for callers that
want to pre-check before extracting
Tests: 149/149 omnimcode-core unit tests still pass.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
0 commit comments