Skip to content
AnOpenSauceDev edited this page Aug 10, 2024 · 3 revisions

Welcome to the Faster Random wiki!

General

Faster Random is an optimization mod for 1.19+, supporting Fabric & Quilt (and technically NeoForge).

Performance (as of 2024-08-10)

Faster Random's generator is faster than all the generators used within minecraft, but it takes 4X the amount of time (vs Xoroshiro) to construct a generator. Therefore a careful balance needs to be made to gain performance.

(The information below is somewhat outdated)

Faster Random works by using Java 17's new RandomGenerator system, particularly L64X128MixRandom, which re-implements Random and CheckedRandom. Worldgen is used more often with the faster Xoroshiro128PlusPlusRandom generator built into minecraft, but still seems to be slower than the solution used by Faster Random. (I will try to look into this when I have the time). As of recently, performance seems to be based off a lot of factors, of which I need to look further into.

That being said, The base two randoms are used quite extensively within Minecraft, and Faster Random does seem to improve performance just looking at the numbers vs. Vanilla themselves.

Debugging/Benchmarking

Faster Random can be benchmarked by running the runTestMod gradle task. Performance seems to be consistent between AMD CPUs. The benchmark data used in the graphic was taken on a 5700X, with 64GB of ram, and the results were consistently similar.

Clone this wiki locally