-
Notifications
You must be signed in to change notification settings - Fork 274
Property reporting utilities [blocks: 3584] #3583
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Property reporting utilities [blocks: 3584] #3583
Conversation
67ad462
to
7943da0
Compare
src/goto-checker/goto_checker.h
Outdated
@@ -59,6 +59,11 @@ class goto_checkert | |||
/// This builds and returns the counterexample | |||
virtual goto_tracet build_error_trace() const = 0; | |||
|
|||
/// This outputs an error witness | |||
virtual void output_error_witness(const goto_tracet &) = 0; | |||
/// This outputs an proof |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/an/a/
src/goto-checker/goto_checker.h
Outdated
/// This outputs an error witness | ||
virtual void output_error_witness(const goto_tracet &) = 0; | ||
/// This outputs an proof | ||
virtual void output_proof() = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there actually no users of goto_checkert
at this point (I've partly lost sight of which commits are or aren't currently on the stack)? Otherwise some implementation would have to be added to make sure things compile even with just this commit.
// collect properties in a vector | ||
std::vector<propertiest::const_iterator> sorted_properties; | ||
for(auto p_it = properties.begin(); p_it != properties.end(); p_it++) | ||
sorted_properties.push_back(p_it); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we should introduce sorted ranges (i.e., add a sort
alongside concat
, filter
)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to confirm as discussed out of band: this was just an idea while reading this code, no need for changes in here.
7943da0
to
a312377
Compare
a312377
to
3330164
Compare
To count how many properties have a certain status. This will be used in property reporting.
Plain text, XML and JSON output for property results.
Prints the property report in plain text, JSON or XML.
3330164
to
519fb98
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✔️
Passed Diffblue compatibility checks (cbmc commit: 519fb98).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/97168198
} | ||
log.status() << "\n** " | ||
<< count_properties(properties, property_statust::FAIL) | ||
<< " of " << properties.size() << " failed" << messaget::eom; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we really print this unconditionally?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's what is happening at the moment: https://github.com/diffblue/cbmc/blob/develop/src/cbmc/all_properties.cpp#L246
Which condition do you have in mind?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yes, I had missed that.
{ | ||
xmlt xml_result("result"); | ||
xml_result.set_attribute("property", id2string(property_id)); | ||
xml_result.set_attribute("status", as_string(property_info.status)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing description
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's what we are doing at the moment: https://github.com/diffblue/cbmc/blob/develop/src/cbmc/all_properties.cpp#L258
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It still seems wrong.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Filed as #3798.
Based on #3579, only review last 4 commits.