Mojira Archive
MC-239582

net.minecraft.util.math.MathHelper

I apologize immediately for possible mistakes, I am not a native English speaker.
It will be about net.minecraft.util.math.MathHelper methods such as (sign, floor, ceil, max/min and others (not including optimized sin/cos functions) since minecraft 1.17, which starts working on java 16+ java.lang.Math more and more methods have IntrinsicCandidate. In the code of minecraft itself many inline methods of max/min methods for example, which can be safely changed to optimized java.lang.Math.max/min methods The lion's share of methods from net.minecraft.util.math.MathHelper doesn't make sense and will be slower than java.lang.Math (depends on the platform), I suggest cutting out the entire legacy code.
I understand I illegally looked at the minecraft code, but I hope it will help improve the performance of the game with minimal effort, because these methods are called often enough

Invalid

Zelva Lea

2021-10-22, 12:44 PM

2021-11-03, 08:25 AM

2021-11-03, 08:25 AM

3

3

Plausible

Performance

1.17.1, 21w42a

-