MCPcopy Create free account
hub / github.com/numpy/numpy / pcg64_cm_next32

Function pcg64_cm_next32

numpy/random/src/pcg64/pcg64.h:402–412  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

400}
401
402static inline uint32_t pcg64_cm_next32(pcg64_state *state) {
403 uint64_t next;
404 if (state->has_uint32) {
405 state->has_uint32 = 0;
406 return state->uinteger;
407 }
408 next = pcg_cm_random_r(state->pcg_state);
409 state->has_uint32 = 1;
410 state->uinteger = (uint32_t)(next >> 32);
411 return (uint32_t)(next & 0xffffffff);
412}
413
414void pcg64_advance(pcg64_state *state, uint64_t *step);
415void pcg64_cm_advance(pcg64_state *state, uint64_t *step);

Callers

nothing calls this directly

Calls 1

pcg_cm_random_rFunction · 0.85

Tested by

no test coverage detected