diff --git a/src/main/java/me/cortex/voxy/client/TimingStatistics.java b/src/main/java/me/cortex/voxy/client/TimingStatistics.java index b88268d5..fcf4346e 100644 --- a/src/main/java/me/cortex/voxy/client/TimingStatistics.java +++ b/src/main/java/me/cortex/voxy/client/TimingStatistics.java @@ -29,9 +29,7 @@ public class TimingStatistics { throw new IllegalStateException(); } this.running = true; - VarHandle.fullFence(); this.timestamp = System.nanoTime(); - VarHandle.fullFence(); } public void stop() { @@ -39,9 +37,7 @@ public class TimingStatistics { throw new IllegalStateException(); } this.running = false; - VarHandle.fullFence(); this.runtime += System.nanoTime() - this.timestamp; - VarHandle.fullFence(); } public void subtract(TimeSampler sampler) { diff --git a/src/main/java/me/cortex/voxy/client/core/model/ModelBakerySubsystem.java b/src/main/java/me/cortex/voxy/client/core/model/ModelBakerySubsystem.java index f8a33b8b..894b9cd4 100644 --- a/src/main/java/me/cortex/voxy/client/core/model/ModelBakerySubsystem.java +++ b/src/main/java/me/cortex/voxy/client/core/model/ModelBakerySubsystem.java @@ -74,8 +74,6 @@ public class ModelBakerySubsystem { } }*/ //TimingStatistics.modelProcess.start(); - long start = System.nanoTime(); - VarHandle.fullFence(); if (this.blockIdCount.get() != 0) { long budget = Math.min(totalBudget-150_000, totalBudget-(this.factory.resultJobs.size()*10_000L))-150_000; @@ -100,7 +98,7 @@ public class ModelBakerySubsystem { this.factory.tick(); - start = System.nanoTime(); + long start = System.nanoTime(); while (!this.factory.resultJobs.isEmpty()) { this.factory.resultJobs.poll().run(); if (totalBudget<(System.nanoTime()-start)) diff --git a/src/main/java/me/cortex/voxy/common/world/ActiveSectionTracker.java b/src/main/java/me/cortex/voxy/common/world/ActiveSectionTracker.java index fedca7c9..3e7077fb 100644 --- a/src/main/java/me/cortex/voxy/common/world/ActiveSectionTracker.java +++ b/src/main/java/me/cortex/voxy/common/world/ActiveSectionTracker.java @@ -130,9 +130,9 @@ public class ActiveSectionTracker { } section.acquire(); - VarHandle.fullFence();//Do not reorder setting this object + VarHandle.storeStoreFence();//Do not reorder setting this object holder.obj = section; - VarHandle.fullFence(); + VarHandle.releaseFence(); if (nullOnEmpty && status == 1) {//If its air return null as stated, release the section aswell section.release(); return null;