mirror of
https://github.com/kvazar-network/kevacoin.git
synced 2025-01-11 15:48:05 +00:00
Merge #10272: [Tests] Prevent warning: variable 'x' is uninitialized
5ec8836
Prevent warning: variable 'x' is uninitialized (Pavel Janík)
Tree-SHA512: 54e39d4b85303db033bd08c52ff2fa093ec9a1b1b9550911bb2123be60fa471cba81f36859681170695dfafb3a8a4c154122917c05b5a23837cf97c25907afc1
This commit is contained in:
commit
54e2d87e79
@ -73,7 +73,7 @@ static void SipHash_32b(benchmark::State& state)
|
|||||||
static void FastRandom_32bit(benchmark::State& state)
|
static void FastRandom_32bit(benchmark::State& state)
|
||||||
{
|
{
|
||||||
FastRandomContext rng(true);
|
FastRandomContext rng(true);
|
||||||
uint32_t x;
|
uint32_t x = 0;
|
||||||
while (state.KeepRunning()) {
|
while (state.KeepRunning()) {
|
||||||
for (int i = 0; i < 1000000; i++) {
|
for (int i = 0; i < 1000000; i++) {
|
||||||
x += rng.rand32();
|
x += rng.rand32();
|
||||||
@ -84,7 +84,7 @@ static void FastRandom_32bit(benchmark::State& state)
|
|||||||
static void FastRandom_1bit(benchmark::State& state)
|
static void FastRandom_1bit(benchmark::State& state)
|
||||||
{
|
{
|
||||||
FastRandomContext rng(true);
|
FastRandomContext rng(true);
|
||||||
uint32_t x;
|
uint32_t x = 0;
|
||||||
while (state.KeepRunning()) {
|
while (state.KeepRunning()) {
|
||||||
for (int i = 0; i < 1000000; i++) {
|
for (int i = 0; i < 1000000; i++) {
|
||||||
x += rng.randbool();
|
x += rng.randbool();
|
||||||
|
Loading…
Reference in New Issue
Block a user