Skip to content
BonsUnleashed edited this page Oct 7, 2026 · 3 revisions

Pehkui

Minecraft 1.20.1 / Forge: this page documents that build and its measurements. For the separate 170-control Minecraft 1.21.1 port, see Minecraft 1.21.1 NeoForge.

One control for Pehkui 3.8.2 (mod id pehkui): scale ticks no longer build callbacks for callback lists that are empty. The switch checks the code it would change against the tested build; another build is left untouched with one WARN line (see How the patches are applied).

Key Target Side Since Kind
pehkui_scale_tick_callbacks Pehkui 3.8.2 BOTH 1.0.28 opt

pehkui_scale_tick_callbacks

Since: 1.0.28 · Target: Pehkui 3.8.2 · Side: BOTH · Kind: opt

Mixin: ScaleUtilsTickMixin

Pehkui scale ticks without empty callback loops. Pehkui ticks all 32 scale types of every entity every tick, and each tick handed a new lambda to the pre-tick and the post-tick callback list, although both lists are empty unless an addon registers a callback: about 64 objects per entity per tick. The lambda is now built, and the list walked, only when the list has callbacks; a non-empty list runs exactly as before, in the same order.

Measured: 32 -> 0 B per scale-type tick; 15-24 -> 9 ns once the call site is shared with other code, as in a full pack (no change in an isolated bench); 717,378 trace lines identical.

Bons and Furious

Minecraft 1.20.1 / Forge 1.0.34

Compatibility

Controls by mod

Links

Clone this wiki locally