Docs / nablatensor-engine-cpu / com.nablatensor.engine.jit

final class

JitPhilox

Per-path random generation for the JIT engine. The default stream's normal draws are bit-identical to com.nablatensor.engine.cpu.Philox so the generated kernel's prices match the scalar reference; a named stream folds its index into the key, and uniforms take a high-tagged counter range so they never alias normals. JitReplay fills the flat draw buffer once per path before invoking the kernel, which then just indexes it.

Methods

static void fillNormals(double[] out, int count, long path, long seed)

Default-stream normals into out[0 .. count), fast math off (legacy signature).

static void fillNormals(double[] out, int count, long path, long seed, boolean fastMath)

Default-stream normals into out[0 .. count) (legacy signature).

static void fillNormals(double[] out, int off, int count, long path, long seed, int stream, boolean fastMath)

Fills out[off .. off+count) with stream stream's standard-normal draws for this path. Each Philox block yields a Box-Muller pair (cosine leg for an even index, sine leg for the odd one), so the transcendentals run once per two draws. For stream == 0 the stream is bit-for-bit the historical single-stream generator.

static void fillUniforms(double[] out, int off, int count, long path, long seed, int stream)

Fills out[off .. off+count) with stream stream's uniform [0,1) draws.