test/timeout.cpp
/*******************************************************************************
    Verifies that our timeouts work correctly.
*******************************************************************************/
Verifies that our timeouts work correctly.
Verifies that our timeouts work correctly .
void check_timeout(dynamic_truth_table& tt, int conflict_limit, vector<double>& times)
{
    spec spec;
    spec.conflict_limit = conflict_limit;
    spec[0] = tt;
    spec.verbosity = 0;
    chain chain;
    auto start = std::clock();
    auto res = synthesize(spec, chain, SLV_BSAT2, ENC_FENCE, SYNTH_FENCE);
    auto elapsed = std::clock()-start;
    times.push_back(elapsed / (double) CLOCKS_PER_SEC);
    assert(res == timeout);
}
void check_timeout ( dynamic_truth_table & tt , int conflict_limit , vector < double > & times ) { spec spec ; spec . conflict_limit = conflict_limit ; spec [ 0 ] = tt ; spec . verbosity = 0 ; chain chain ; auto start = std :: clock ( ) ; auto res = synthesize ( spec , chain , SLV_BSAT2 , ENC_FENCE , SYNTH_FENCE ) ; auto elapsed = std :: clock ( ) - start ; times . push_back ( elapsed / ( double ) CLOCKS_PER_SEC ) ; assert ( res == timeout ) ; }
Verifies that our timeouts work correctly.
Verifies that our timeouts work correctly .
//assert(solver_nr_conflicts(spec.solver()) >= conflict_limit);