-
Notifications
You must be signed in to change notification settings - Fork 273
Ensure one backedge per target: restore lexical loops #7321
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
Ensure one backedge per target: restore lexical loops #7321
Conversation
Codecov ReportBase: 78.28% // Head: 78.29% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## develop #7321 +/- ##
========================================
Coverage 78.28% 78.29%
========================================
Files 1642 1642
Lines 189995 190068 +73
========================================
+ Hits 148737 148806 +69
- Misses 41258 41262 +4
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
b12023d
to
2edc836
Compare
Should the loop counters be fixed instead? Say by tracking pairs of locations instead of just the target? |
Seems desirable, but would it actually work? Is it just the loop header that we want to track? |
Figure-of-eight loop pairs may indeed have just one backedge, but still confused symex' unwinding counters. Re-create properly nested lexical loops from such loop pairs to avoid this problem.
2edc836
to
c127049
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.
Identifying loops by two locations has obvious advantages (less reliance on a 'normalised' GOTO program). I'm fine with either approach as long as we clearly document our assumptions. In 2LS we also normalise loops so that each loop head is a separate location.
Making changes to the program will, of course, break any user who expects counterexamples to follow the original program. I'd also prefer to use a pair to identify the loops instead. |
Figure-of-eight loop pairs may indeed have just one backedge, but still confused symex' unwinding counters. Re-create properly nested lexical loops from such loop pairs to avoid this problem.