From bbf7d60abe1e8a83ac4dda506262a05cf11d4c2e Mon Sep 17 00:00:00 2001 From: mcrcortex <18544518+MCRcortex@users.noreply.github.com> Date: Mon, 15 Dec 2025 12:54:59 +1000 Subject: [PATCH] todo --- src/main/java/me/cortex/voxy/common/world/WorldUpdater.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/me/cortex/voxy/common/world/WorldUpdater.java b/src/main/java/me/cortex/voxy/common/world/WorldUpdater.java index 8491a049..1a97702f 100644 --- a/src/main/java/me/cortex/voxy/common/world/WorldUpdater.java +++ b/src/main/java/me/cortex/voxy/common/world/WorldUpdater.java @@ -55,7 +55,11 @@ public class WorldUpdater { final int iSecMsk1 = (~secMsk) + 1; int secIdx = 0; - //TODO: manually unroll and do e.g. 4 iterations per loop + + //TODO rotate the loop parralelization + // i.e. instead of doing 4 consecutive blocks, which would all be in the same cache line + // do 4 seperate rows so they are in different cache lines, should allow + // more instruction pipelining (in theory) for (int i = 0; i <= 0xFFF; i+=4) { int cSecIdx = secIdx + baseSec; secIdx = (secIdx + iSecMsk1) & secMsk;