Skip to content

Race condition in rng? #459

@biddisco

Description

@biddisco

By chance I notice that the turbulence test fails from time to time. This repeated soak test gives more info

tries=1000; count=0; for i in `seq 1 $tries`; do echo $i; output=`ctest --output-on-failure -R turbulence_tests 2>&1 >> fail.txt`; if [ -z "$output" ]; then count=$(($count+1)); fi; done; echo "$count out of $tries completed successfully"

produces

964 out of 1000 completed successfully

on average it seems to be failing 3.5% of the time. Examining the fail.txt file shows output of the form

Total Test time (real) =   0.01 sec
Test project /home/biddisco/build/sphexa
    Start 30: turbulence_tests
1/1 Test #30: turbulence_tests .................***Failed    0.01 sec
[==========] Running 1 test from 1 test suite.
[----------] Global test environment set-up.
[----------] 1 test from Turbulence
[ RUN      ] Turbulence.rngSerialize
/home/biddisco/src/sphexa/sph/test/hydro_turb/rng.cpp:66: Failure
Expected equality of these values:
  originalEngine
    Which is: 42 3107752595 1895908407 3900362577 3030691166 4081230161 2732361568 1361238961 3961642104 867618704 2837705690 3281374275 3928479052 3691474744 3088217429 1769265762 37695088
etc etc etc

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions