Symex-driven lazy loading uses goto-checker [blocks: #2212]#4541
Symex-driven lazy loading uses goto-checker [blocks: #2212]#4541peterschrammel merged 14 commits intodiffblue:developfrom
Conversation
1d7c902 to
aa3dda9
Compare
allredj
left a comment
There was a problem hiding this comment.
This PR failed Diffblue compatibility checks (cbmc commit: aa3dda9).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/108567170
Status will be re-evaluated on next push.
Common spurious failures include: the cbmc commit has disappeared in the mean time (e.g. in a force-push); the author is not in the list of contributors (e.g. first-time contributors); compatibility was already broken by an earlier merge.
allredj
left a comment
There was a problem hiding this comment.
This PR failed Diffblue compatibility checks (cbmc commit: 1ce9697).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/108568076
Status will be re-evaluated on next push.
Common spurious failures include: the cbmc commit has disappeared in the mean time (e.g. in a force-push); the author is not in the list of contributors (e.g. first-time contributors); compatibility was already broken by an earlier merge.
jbmc/src/jbmc/jbmc_parse_options.cpp
Outdated
| goto_function, | ||
| symbol_table, | ||
| get_message_handler()); | ||
| log.get_message_handler()); |
There was a problem hiding this comment.
Nit pick: I think this change is in the wrong commit as it is a fix-up for the previous change.
jbmc/src/jbmc/jbmc_parse_options.cpp
Outdated
| { | ||
| // We can only output these after goto-symex has run. | ||
| (void)show_loaded_symbols(*goto_model_ptr); | ||
| (void)show_loaded_functions(*goto_model_ptr); |
There was a problem hiding this comment.
I don't understand this bit of code: the comment says that we cannot do any of this output, but then invokes two output functions, which seems like a contradiction. And then why does it do any output at all here, where has this been requested?
There was a problem hiding this comment.
It says we needed to wait until after symex, which we just ran (the verifier() call above)
There was a problem hiding this comment.
(normally of course we can --show-goto-functions before symex, but not when symex itself is deciding what gets loaded)
There was a problem hiding this comment.
Ok, but why are we doing this output at all?
| // have we got anything to check? otherwise we return PASS | ||
| if(!has_properties_to_check(properties)) | ||
| return resultt::PASS; | ||
|
|
There was a problem hiding this comment.
The commit message suggests that this code must be put somewhere else, but then the commit only removes code?
There was a problem hiding this comment.
incremental_goto_checker is already doing that.
jbmc/src/jbmc/jbmc_parse_options.cpp
Outdated
| return get_goto_program_ret; | ||
|
|
||
| if(!cmdline.isset("symex-driven-lazy-loading")) | ||
| if(!options.get_bool_option("symex-driven-lazy-loading")) |
There was a problem hiding this comment.
Is there anything we could do to completely hide cmdline from such code so that it cannot wrongly be reintroduced?
| propertiest initialize_properties(const abstract_goto_modelt &goto_model) | ||
| { | ||
| propertiest properties; | ||
| update_properties_from_goto_model(properties, goto_model); |
There was a problem hiding this comment.
@tautschnig I believe this might be the resolution to your complain about check-properties code being deleted? (perhaps these two commits should be merged?)
There was a problem hiding this comment.
"check-properties code being deleted" - what is this about?
There was a problem hiding this comment.
Where you said "incremental_goto_checker is already doing that."
smowton
left a comment
There was a problem hiding this comment.
Thankyou, this factors the symex-driven stuff much better than I managed back when I first wrote this!
reduces code duplication
removes indent
set_properties has no return value.
reduces code duplication
is unreachable
With symex-driven-lazy-loading there might not be any properties initially. Incremental_goto_checker is already doing that check anyway.
With symex-driven-lazy-loading we know the full set of properties only after goto-symex has finished.
Only use options after cmdline has been parsed into options.
goes now through goto-checker classes instead of bmct/all_propertiest.
reduces indentation
These have now been entirely replaced by goto-checker.
1ce9697 to
f96818d
Compare
allredj
left a comment
There was a problem hiding this comment.
This PR failed Diffblue compatibility checks (cbmc commit: f96818d).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/108667061
Status will be re-evaluated on next push.
Common spurious failures include: the cbmc commit has disappeared in the mean time (e.g. in a force-push); the author is not in the list of contributors (e.g. first-time contributors); compatibility was already broken by an earlier merge.
Most of this PR are incremental clean-ups of jbmc_parse_optionst. Review commit by commit.