This PR refactors the process of outputting proof hints to file so that it is handled by an abstract proof_trace_writer. We then implement a subclass of the proof_trace_writer class, namely proof_trace_file_writer, that outputs the proof hints to a binary file.
We do that so that we can easily add other methods of outputting proof hints in the future, such as a shared memory / ringbuffer based writer that will work in tandem with the shared memory proof hints parser that was recently merged.
The PR can be easily reviewed commit by commit.
the first 3 commits do some preparatory refactoring to normalize naming conventions that will make the big refactoring more straightforward.
the 4th commit replaces the writer * argument of proof trace output functions with a FILE * argument, since this is the only part of the writer class that is used when it comes to hint generation.
the 5th commit refactors all FILE * pointers related to hint generation into pointers to a placeholder class which simply wraps said FILE *. It also does some function renaming to better reflect that these functions participate in the hint generation output process.
the 6th commit replaces the placeholder class with the abstract proof_trace_writer class and adds a concrete subclass for writing into a file, namely proof_trace_file_writer.
@Baltoli I don't know if you will have the time to review this one so I didn't ask for a review. If you do have the time, your comments are always welcome and appreciated!
This PR refactors the process of outputting proof hints to file so that it is handled by an abstract
proof_trace_writer
. We then implement a subclass of theproof_trace_writer
class, namelyproof_trace_file_writer
, that outputs the proof hints to a binary file.We do that so that we can easily add other methods of outputting proof hints in the future, such as a shared memory / ringbuffer based writer that will work in tandem with the shared memory proof hints parser that was recently merged.
The PR can be easily reviewed commit by commit.
writer *
argument of proof trace output functions with aFILE *
argument, since this is the only part of thewriter
class that is used when it comes to hint generation.FILE *
pointers related to hint generation into pointers to a placeholder class which simply wraps saidFILE *
. It also does some function renaming to better reflect that these functions participate in the hint generation output process.proof_trace_writer
class and adds a concrete subclass for writing into a file, namelyproof_trace_file_writer
.