This commit is contained in:
RePixelatedMC
2023-11-26 19:02:50 +01:00
parent 47990cde46
commit c30de98449
@@ -443,7 +443,6 @@ public class Mantle {
dynamicThreads.set(IrisSettings.get().getPerformance().getTectonicUnloadThreads()); dynamicThreads.set(IrisSettings.get().getPerformance().getTectonicUnloadThreads());
} }
} }
int dth = dynamicThreads.get();
adjustedIdleDuration.set(baseIdleDuration); adjustedIdleDuration.set(baseIdleDuration);
@@ -501,10 +500,10 @@ public class Mantle {
} }
} }
// BurstExecutor burstExecutor = new BurstExecutor(Executors.newFixedThreadPool(1), toUnload.size()); BurstExecutor burstExecutor = new BurstExecutor(Executors.newFixedThreadPool(dynamicThreads.get()), toUnload.size());
for (Long i : toUnload) { for (Long i : toUnload) {
// burstExecutor.queue(() -> { burstExecutor.queue(() -> {
hyperLock.withLong(i, () -> { hyperLock.withLong(i, () -> {
TectonicPlate m = loadedRegions.get(i); TectonicPlate m = loadedRegions.get(i);
if (m != null) { if (m != null) {
@@ -519,10 +518,9 @@ public class Mantle {
} }
} }
}); });
// }); });
} }
// burstExecutor.complete(); burstExecutor.complete();
} finally { } finally {
io.set(false); io.set(false);
} }