even even even more work

This commit is contained in:
MiniDigger | Martin
2020-06-25 16:09:55 +02:00
parent 4aa7955818
commit e943ece469
125 changed files with 857 additions and 3512 deletions

View File

@@ -16,13 +16,13 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -0,0 +0,0 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
dedicatedserver.setEraseCache(true);
}
S s0 = function.apply(thread); // CraftBukkit - decompile error
+ dedicatedserver.serverThread.setPriority(Thread.NORM_PRIORITY+2); // Paper - boost priority
dedicatedserver.serverThread.start();
// CraftBukkit end
} catch (Exception exception) {
atomicreference.set(s0);
+ thread.setPriority(Thread.NORM_PRIORITY+2); // Paper - boost priority
thread.start();
return s0;
}
diff --git a/src/main/java/net/minecraft/server/ServerWorkerThread.java b/src/main/java/net/minecraft/server/ServerWorkerThread.java
new file mode 100644
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000
@@ -60,7 +60,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
@@ -0,0 +0,0 @@ public class SystemUtils {
}
private static ExecutorService k() {
private static ExecutorService a(String s) {
- int i = MathHelper.clamp(Runtime.getRuntime().availableProcessors() - 1, 1, 7);
- Object object;
+ // Paper start - use simpler thread pool that allows 1 thread
@@ -80,10 +80,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
if (throwable != null) {
SystemUtils.LOGGER.warn("{} died", this.getName(), throwable);
@@ -0,0 +0,0 @@ public class SystemUtils {
SystemUtils.LOGGER.error(String.format("Caught exception in thread %s", thread), throwable);
}, true);
- }
return forkjoinworkerthread;
}, SystemUtils::a, true);
}
+ }*/ // Paper end
return (ExecutorService) object;