if (debugTraceEnabled)
{
- Trace("tconv-pf-gen-debug") << "Printing rewrite steps..." << std::endl;
+ Trace("tconv-pf-gen-debug") << "Rewrite steps:" << std::endl;
for (size_t r = 0; r < 2; r++)
{
const NodeNodeMap& rm = r == 0 ? d_preRewriteMap : d_postRewriteMap;
std::shared_ptr<ProofNode> pfn = lpf.getProofFor(f);
Trace("tconv-pf-gen") << "... success" << std::endl;
Assert(pfn != nullptr);
- Trace("tconv-pf-gen-debug") << "... proof is " << *pfn << std::endl;
+ Trace("tconv-pf-gen-debug-pf") << "... proof is " << *pfn << std::endl;
return pfn;
}
}
std::shared_ptr<ProofNode> pfn = lpf.getProofFor(conc);
Assert(pfn != nullptr);
- Trace("tconv-pf-gen-debug") << "... proof is " << *pfn << std::endl;
+ Trace("tconv-pf-gen-debug-pf") << "... proof is " << *pfn << std::endl;
return pfn;
}
rtfNode = ttfr.getNode();
registerTrustedRewrite(ttfr, d_tpgRtf.get(), true);
}
- // Finish the conversion by rewriting. This is registered as a
- // post-rewrite, since it is the last step applied for theory atoms.
- Node retNode = rewriteWithProof(rtfNode, d_tpgRtf.get(), false);
+ // Finish the conversion by rewriting. Notice that we must consider this a
+ // pre-rewrite since we do not recursively register the rewriting steps
+ // of subterms of rtfNode. For example, if this step rewrites
+ // (not A) ---> B, then if registered a pre-rewrite, it will apply when
+ // reconstructing proofs via d_tpgRtf. However, if it is a post-rewrite
+ // it will fail to apply if another call to this class registers A -> C,
+ // in which case (not C) will be returned instead of B (see issue 6754).
+ Node retNode = rewriteWithProof(rtfNode, d_tpgRtf.get(), true);
d_rtfCache[current] = retNode;
continue;
}
regress0/preprocess/circuit-prop.smt2
regress0/preprocess/issue5729-rewritten-assertions.smt2
regress0/preprocess/issue5943-non-clausal-simp.smt2
+ regress0/preprocess/issue6754-tpp.smt2
regress0/preprocess/preprocess_00.cvc
regress0/preprocess/preprocess_01.cvc
regress0/preprocess/preprocess_02.cvc