mirror of
https://github.com/Z3Prover/z3
synced 2025-08-08 04:01:22 +00:00
micro-optimization in tactics' cleanup(): avoid dealloc+alloc traffic
This commit is contained in:
parent
632c2d8ebf
commit
000796c25c
3 changed files with 7 additions and 10 deletions
|
@ -307,9 +307,8 @@ public:
|
|||
|
||||
virtual void cleanup() {
|
||||
ast_manager & m = m_imp->m;
|
||||
imp * d = alloc(imp, m, m_params);
|
||||
std::swap(d, m_imp);
|
||||
dealloc(d);
|
||||
m_imp->~imp();
|
||||
m_imp = new (m_imp) imp(m, m_params);
|
||||
}
|
||||
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue