Multi-core simulation: grain movement and heat across a worker pool (t88 phase 3)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-28 03:23:43 -04:00
co-authored by Claude Opus 5.5
parent 20963c776e
commit 7468d00efb
35 changed files with 578 additions and 113 deletions
Binary file not shown.
Binary file not shown.
+5 -3
View File
@@ -1,4 +1,4 @@
// Reference heat loop before t21 phase 3; preserves conduction and Float32 store order.
// Unoptimized heat oracle, re-baselined for t88 chunk-pass heat outputs.
function referenceHeatChunk(c, sc) {
const cx = c % CW, cy = (c / CW) | 0;
const x0 = cx << 5, y0 = cy << 5, x1 = Math.min(W, x0 + 32), y1 = Math.min(H, y0 + 32);
@@ -37,6 +37,8 @@ function referenceHeatChunk(c, sc) {
if (flags[i] & F_BURN) burning = true;
}
}
if (burning || maxDev > 1.5) { hot[c] = 6; hotLvl[c] = (burning || maxDev > 60) ? 2 : 1; }
else hot[c]--;
const h = burning || maxDev > 1.5 ? 6 : hot[c] - 1;
const level = burning || maxDev > 1.5 ? ((burning || maxDev > 60) ? 2 : 1) : hotLvl[c];
if (chunkWork) { chunkWork.ownHot[c] = h; chunkWork.ownLevel[c] = level; }
else { hot[c] = h; hotLvl[c] = level; }
}