[PR #25] [MERGED] Disclose frozen and altered tick workloads in benchmark reports #2275

Closed
opened 2026-11-02 15:54:33 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/25
Author: @ludovic111
Created: 10/4/2026
Status: ✅ Merged
Merged: 10/4/2026
Merged by: @ludovic111

Base: main ← Head: benchmark-tick-state


📝 Commits (2)

  • 02d7a51 Capture sampled tick-manager changes without altering simulation
  • 7d56159 Verify restored tick states in a live disposable world and explain sampled TPS

📊 Changes

16 files changed (+459 additions, -10 deletions)

View changed files

📝 .github/workflows/ci.yml (+2 -0)
📝 README.md (+2 -2)
➕ benchmarks/tick-state-2026-10-04/live-observations.json (+78 -0)
➕ docs/tick-state.md (+26 -0)
📝 mods/horizon-lab/src/main/java/dev/horizonlab/HorizonLab.java (+3 -2)
📝 mods/horizon-lab/src/main/java/dev/horizonlab/metrics/Recording.java (+13 -1)
➕ mods/horizon-lab/src/main/java/dev/horizonlab/metrics/TickState.java (+76 -0)
📝 mods/horizon-lab/src/main/resources/fabric.mod.json (+1 -1)
📝 mods/horizon-lab/src/test/java/dev/horizonlab/metrics/MetricsTest.java (+31 -0)
➕ mods/horizon-lab/src/test/java/dev/horizonlab/metrics/TickStateIntegration.java (+70 -0)
📝 packs/START-HERE.txt (+5 -0)
📝 packs/mods.lock.json (+1 -1)
📝 tests/test_packs.py (+49 -0)
📝 tools/Compare-Benchmarks.html (+42 -2)
📝 tools/build_mod.py (+1 -1)
📝 tools/compare_benchmarks.py (+59 -0)

📄 Description

Frozen tick invocations can look inexpensive and still count toward observed TPS. A configured tick rate changed and restored during a recording was previously absent from workload context. Capture the server tick manager after measured invocations, retaining sampled rate/freeze/step/sprint/game-element changes even when first and last states match. State and duration acceptance share the recording lock; the observation path retains scalars, and invalid observations leave timing capture operational.

Both comparison tools flag changed or differing sampled states, warn about nonstandard workloads and leave legacy/invalid state unknown. State-map ordering does not create false differences. The offline viewer wraps long state details on mobile. Documentation distinguishes observed invocation rate, execution capacity and completed simulation work, including sampling/paused/last-stepping-tick limits. Bump distributable metadata to 0.20.0; the instrumentation reads state without changing simulation.

Validation: 44 offline checks, recording checks under ordinary/compact-header/ZGC configurations, actual discarded paused-capture JSON/CSV viewer checks, restored-state/map-order/invalid-state checks, and desktop/390-pixel layouts pass locally. A private disposable-world applied-hook fixture observes all five changes, restores matching first/last states, verifies count equality and exits zero. The final rebuilt binary records 285 invocations, preserves all five changes after matching restored boundary states, matches CSV counts/means, records zero invalid/dropped samples and exits zero. Actual final report/CSV charts and desktop/mobile warnings pass. Final revision 7d561596d6 passes all four jobs in run 37183878198, and the independently built Linux production JAR matches locally byte-for-byte. The fixture source is compiled in platform CI but its private binary is excluded from playable packages; live Mac performance has not been measured.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/25 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/4/2026 **Status:** ✅ Merged **Merged:** 10/4/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `benchmark-tick-state` --- ### 📝 Commits (2) - [`02d7a51`](https://github.com/horizon-rust/horizon/commit/02d7a5189d82a1bd528ca64148e17fc74700da6f) Capture sampled tick-manager changes without altering simulation - [`7d56159`](https://github.com/horizon-rust/horizon/commit/7d561596d6c3be02713edd0fd962b3ee61af11ef) Verify restored tick states in a live disposable world and explain sampled TPS ### 📊 Changes **16 files changed** (+459 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `.github/workflows/ci.yml` (+2 -0) 📝 `README.md` (+2 -2) ➕ `benchmarks/tick-state-2026-10-04/live-observations.json` (+78 -0) ➕ `docs/tick-state.md` (+26 -0) 📝 `mods/horizon-lab/src/main/java/dev/horizonlab/HorizonLab.java` (+3 -2) 📝 `mods/horizon-lab/src/main/java/dev/horizonlab/metrics/Recording.java` (+13 -1) ➕ `mods/horizon-lab/src/main/java/dev/horizonlab/metrics/TickState.java` (+76 -0) 📝 `mods/horizon-lab/src/main/resources/fabric.mod.json` (+1 -1) 📝 `mods/horizon-lab/src/test/java/dev/horizonlab/metrics/MetricsTest.java` (+31 -0) ➕ `mods/horizon-lab/src/test/java/dev/horizonlab/metrics/TickStateIntegration.java` (+70 -0) 📝 `packs/START-HERE.txt` (+5 -0) 📝 `packs/mods.lock.json` (+1 -1) 📝 `tests/test_packs.py` (+49 -0) 📝 `tools/Compare-Benchmarks.html` (+42 -2) 📝 `tools/build_mod.py` (+1 -1) 📝 `tools/compare_benchmarks.py` (+59 -0) </details> ### 📄 Description Frozen tick invocations can look inexpensive and still count toward observed TPS. A configured tick rate changed and restored during a recording was previously absent from workload context. Capture the server tick manager after measured invocations, retaining sampled rate/freeze/step/sprint/game-element changes even when first and last states match. State and duration acceptance share the recording lock; the observation path retains scalars, and invalid observations leave timing capture operational. Both comparison tools flag changed or differing sampled states, warn about nonstandard workloads and leave legacy/invalid state unknown. State-map ordering does not create false differences. The offline viewer wraps long state details on mobile. Documentation distinguishes observed invocation rate, execution capacity and completed simulation work, including sampling/paused/last-stepping-tick limits. Bump distributable metadata to 0.20.0; the instrumentation reads state without changing simulation. Validation: 44 offline checks, recording checks under ordinary/compact-header/ZGC configurations, actual discarded paused-capture JSON/CSV viewer checks, restored-state/map-order/invalid-state checks, and desktop/390-pixel layouts pass locally. A private disposable-world applied-hook fixture observes all five changes, restores matching first/last states, verifies count equality and exits zero. The final rebuilt binary records 285 invocations, preserves all five changes after matching restored boundary states, matches CSV counts/means, records zero invalid/dropped samples and exits zero. Actual final report/CSV charts and desktop/mobile warnings pass. Final revision 7d561596d6c3be02713edd0fd962b3ee61af11ef passes all four jobs in [run 37183878198](https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37183878198), and the independently built Linux production JAR matches locally byte-for-byte. The fixture source is compiled in platform CI but its private binary is excluded from playable packages; live Mac performance has not been measured. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-02 15:54:33 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#2275
No description provided.