magisk-zapret2/tests/shell
Repository files (latest commit first)
Filename Latest commit message Latest commit date
loop-uh 852d42c02e Answer in builtins what the replace path kept re-buying in forks
Android prices every fork at ~25ms and every exec at ~90ms, and the
preset apply was paying that price for questions it had already
answered: 95 separate stat calls re-proving file metadata one field at
a time, command substitutions around proc readers whose parsing was
already builtin-only, expected firewall rules rebuilt through captures
on every verify, and printf — an external binary on Android's mksh —
invoked once per line of every publication.

One stat capture now serves every metadata question a proof asks
(path_meta_capture, consumed by the uid/mode/nlink/size predicates and
retired on proof exit); the state-dir proof and a fully-pinned process
identity become lock-scoped facts on the same single-writer argument as
the owner read cache; proc_starttime/proc_argv0 gain fork-free
global-return forms with the printf wrappers kept as seams; the qnum
argument check reuses the cmdline snapshot argv0 already paid for;
expected firewall rules are built as data instead of captured; and
multi-line writers emit once through z2_emit_line, which resolves to
mksh's raw print builtin on the device and printf elsewhere. Load-time
probes replace the per-call command -v PATH walks, and log stamps reuse
one date exec per second via EPOCHREALTIME.

Measured on the Pixel 9 Pro XL: preset apply 56s before this series,
40s after the owner read cache, 14.6s now. tests/shell/run.sh passes;
the three test seams that named replaced internals (proc_starttime,
z2_fw_restore_command, the owner printf format) follow the new forms.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-25 16:55:22 +03:00
..
boot-recovery.sh Raise the lifecycle contract for the stopped payload's new meaning 2026-07-25 12:14:50 +03:00
error-contract.sh 2.0.1 2026-07-24 00:43:14 +03:00
firewall-reconciler.sh Answer in builtins what the replace path kept re-buying in forks 2026-07-25 16:55:22 +03:00
full-rollback.sh Stop the rollback from re-asking a question it already answered 2026-07-25 13:07:44 +03:00
lifecycle-lock-owner.sh Answer in builtins what the replace path kept re-buying in forks 2026-07-25 16:55:22 +03:00
lifecycle-safety.sh Answer in builtins what the replace path kept re-buying in forks 2026-07-25 16:55:22 +03:00
lifecycle-status-v4.sh Release 2.0.6 with bounded read-only status 2026-07-24 17:06:28 +03:00
lifecycle-status-v5.sh Release 2.0.6 with bounded read-only status 2026-07-24 17:06:28 +03:00
lifecycle-status-v6.sh Release 2.0.7 with bounded runtime catalogs 2026-07-24 18:11:41 +03:00
magisk-boot-installer.sh Accelerate lifecycle startup and status 2026-07-24 23:22:39 +03:00
owner-generation.sh Let the module re-read a generation it published itself 2026-07-25 15:23:33 +03:00
owner-state-v8.sh Remove dead legacy migration, track journals, and WAL reader 2026-07-25 02:16:40 +03:00
package-owner-protocol.sh Accelerate lifecycle startup and status 2026-07-24 23:22:39 +03:00
packaging-recovery-flow.sh Accelerate lifecycle startup and status 2026-07-24 23:22:39 +03:00
preset-contract.sh Accelerate lifecycle startup and status 2026-07-24 23:22:39 +03:00
purge-contract.sh Measure the removal facts on the receipt uninstall failure prints too 2026-07-25 11:25:15 +03:00
release-generation.sh Bound runtime update and status costs 2026-07-23 21:02:23 +03:00
run.sh Close the release-readiness findings 2026-07-25 05:28:16 +03:00
runtime-config-contract.sh 2.0.8 2026-07-24 19:32:25 +03:00
status-snapshot-fast-path.sh Carry the IPv6 reservation across every boundary that reports it 2026-07-25 11:09:07 +03:00
transactional-start.sh Remove dead legacy migration, track journals, and WAL reader 2026-07-25 02:16:40 +03:00