aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0083-Optimize-DataBits.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0083-Optimize-DataBits.patch')
-rw-r--r--patches/server/0083-Optimize-DataBits.patch6
1 files changed, 3 insertions, 3 deletions
diff --git a/patches/server/0083-Optimize-DataBits.patch b/patches/server/0083-Optimize-DataBits.patch
index e11675c807..a769664b4c 100644
--- a/patches/server/0083-Optimize-DataBits.patch
+++ b/patches/server/0083-Optimize-DataBits.patch
@@ -11,7 +11,7 @@ After: http://i.imgur.com/nJ46crB.png
Optimize redundant converting of static fields into an unsigned long each call by precomputing it in ctor
diff --git a/src/main/java/net/minecraft/util/SimpleBitStorage.java b/src/main/java/net/minecraft/util/SimpleBitStorage.java
-index dea4f322f750a0a09407fdb48d5d6e809dfe8ed4..236ce41328758cb173a239133073944adb484dd1 100644
+index b0fc31f8fdf96c5b595b04fe4208963a33de8a2a..dafb714706107a9e83a7c0b808ba795a78eb7b52 100644
--- a/src/main/java/net/minecraft/util/SimpleBitStorage.java
+++ b/src/main/java/net/minecraft/util/SimpleBitStorage.java
@@ -204,8 +204,8 @@ public class SimpleBitStorage implements BitStorage {
@@ -42,10 +42,10 @@ index dea4f322f750a0a09407fdb48d5d6e809dfe8ed4..236ce41328758cb173a239133073944a
private int cellIndex(int index) {
- long l = Integer.toUnsignedLong(this.divideMul);
- long m = Integer.toUnsignedLong(this.divideAdd);
-- return (int)((long)index * l + m >> 32 >> this.divideShift);
+- return (int)(index * l + m >> 32 >> this.divideShift);
+ //long l = Integer.toUnsignedLong(this.divideMul); // Paper - Perf: Optimize SimpleBitStorage
+ //long m = Integer.toUnsignedLong(this.divideAdd); // Paper - Perf: Optimize SimpleBitStorage
-+ return (int) ((long) index * this.divideMulUnsigned + this.divideAddUnsigned >> 32 >> this.divideShift); // Paper - Perf: Optimize SimpleBitStorage
++ return (int) (index * this.divideMulUnsigned + this.divideAddUnsigned >> 32 >> this.divideShift); // Paper - Perf: Optimize SimpleBitStorage
}
@Override