-
Notifications
You must be signed in to change notification settings - Fork 273
Simplify array size expressions #7622
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
Simplify array size expressions #7622
Conversation
Symbolic execution may be able to replace symbolic sizes by constants, but even the symbolic size might include a type cast (for examples, ones arising from uses of havoc_slice). Simplify those expressions to avoid appearance of almost-a-constant expressions.
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## develop #7622 +/- ##
===========================================
+ Coverage 78.13% 78.51% +0.37%
===========================================
Files 1671 1671
Lines 191845 191851 +6
===========================================
+ Hits 149905 150624 +719
+ Misses 41940 41227 -713
... and 34 files with indirect coverage changes 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 in Codecov by Sentry. |
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.
Can this be observed (tested?) somehow?
It seems that |
With diffblue#7622 we may have syntactically changed the type on the right-hand side via simplification. To maintain syntactic type equality we need to apply simplifications on the left-hand side as well. See https://github.com/awslabs/aws-c-common/actions/runs/4822448417 for an example where this failed after diffblue#7622.
With diffblue#7622 we may have syntactically changed the type on the right-hand side via simplification. To maintain syntactic type equality we need to apply simplifications on the left-hand side as well. See https://github.com/awslabs/aws-c-common/actions/runs/4822448417 for an example where this failed after diffblue#7622.
With diffblue#7622 we may have syntactically changed the type on the right-hand side via simplification. To maintain syntactic type equality we need to apply simplifications on the left-hand side as well. See https://github.com/awslabs/aws-c-common/actions/runs/4822448417 for an example where this failed after diffblue#7622.
With diffblue#7622 we may have syntactically changed the type on the right-hand side via simplification. To maintain syntactic type equality we need to apply simplifications on the left-hand side as well. See https://github.com/awslabs/aws-c-common/actions/runs/4822448417 for an example where this failed after diffblue#7622.
Symbolic execution may be able to replace symbolic sizes by constants, but even the symbolic size might include a type cast (for examples, ones arising from uses of havoc_slice). Simplify those expressions to avoid appearance of almost-a-constant expressions.