3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-06-22 05:43:39 +00:00

reduce contention #2842

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2020-01-06 20:10:11 -08:00
parent 670e8f8d67
commit f70696d8e7
3 changed files with 4 additions and 3 deletions

View file

@ -107,7 +107,8 @@ struct th_rewriter_cfg : public default_rewriter_cfg {
bool cache_all_results() const { return m_cache_all; }
bool max_steps_exceeded(unsigned num_steps) const {
if (memory::get_allocation_size() > m_max_memory)
if (m_max_memory != SIZE_MAX &&
memory::get_allocation_size() > m_max_memory)
throw rewriter_exception(Z3_MAX_MEMORY_MSG);
return num_steps > m_max_steps;
}