MCPcopy Create free account
hub / github.com/KhronosGroup/SPIRV-Tools / RandomBool

Method RandomBool

source/fuzz/pseudo_random_generator.cpp:36–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34}
35
36bool PseudoRandomGenerator::RandomBool() {
37 return static_cast<bool>(std::uniform_int_distribution<>(0, 1)(mt_));
38}
39
40uint32_t PseudoRandomGenerator::RandomPercentage() {
41 // We use 101 because we want a result in the closed interval [0, 100], and

Callers 2

ChooseEvenMethod · 0.80
InterestingMethod · 0.80

Calls

no outgoing calls

Tested by 1

InterestingMethod · 0.64