Package kilim.examples
Class Xorshift
- java.lang.Object
-
- kilim.examples.Xorshift
-
public class Xorshift extends java.lang.Objecta demo and benchmark of kilim generators used to implement the xorshift PRNG runs xorshift a number of cycles, printing the nanos per cycle and the xor of the result the value is printed just to ensure that the JIT actually runs all the code https://en.wikipedia.org/wiki/Xorshift#xorshift.2B with modes to run the same algorithm as a Generator and as a raw Continuation (the default)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static interfaceXorshift.Loopstatic classXorshift.X1static classXorshift.X2
-
Constructor Summary
Constructors Constructor Description Xorshift()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static voidcycle(Xorshift.Loop looper, long num)static voidmain(java.lang.String[] args)
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
-
cycle
static void cycle(Xorshift.Loop looper, long num)
-
-