-
Notifications
You must be signed in to change notification settings - Fork 274
Permit initializers in library functions #6590
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
Permit initializers in library functions #6590
Conversation
Codecov ReportBase: 78.41% // Head: 78.39% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## develop #6590 +/- ##
===========================================
- Coverage 78.41% 78.39% -0.03%
===========================================
Files 1655 1655
Lines 190264 190281 +17
===========================================
- Hits 149201 149172 -29
- Misses 41063 41109 +46
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. |
c3f5f03
to
ad72b1e
Compare
ad72b1e
to
a52875a
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.
This seems reasonable and sensible to me.
a52875a
to
236b6ef
Compare
d544bb6
to
10bec57
Compare
10bec57
to
e0d8e54
Compare
e0d8e54
to
1643bed
Compare
{ | ||
changed = true; | ||
added_functions.insert(id); | ||
|
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.
How about reformulating the control flow structure as
if(body_available || already_added)
continue;
// add the symbol
changed = true;
added_functions.insert(id);
...
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.
Could do, but then I'd have to touch more code in this PR.
a9db9b9
to
4572567
Compare
4572567
to
42ddaab
Compare
MSVC won't have the built-in declarations available, and will thus fail type checking.
The test descriptions expect valid enum values, which we didn't actually have any guarantee built into the test for.
This enables type checking of missing functions vs library-provided functions, and also enables type sanitisation as done by the linker. Co-authored-by: Peter Schrammel <[email protected]>
With the support of building initialisers while adding the library we can move library-only symbols to the library. This avoids polluting the initialisation function for all cases that don't actually use pipe-related library functions.
With the support of building initialisers while adding the library we can move library-only symbols to the library. This avoids polluting the initialisation function for all cases that don't actually use memory (de-)allocation library functions.
With the support of building initialisers while adding the library we can move library-only symbols to the library. This avoids polluting the initialisation function for all cases that don't actually use pthreads-related library functions. This removal of unused symbols required adding a symbol into the array_of_bool_as_bitvec test, which previously implicitly relied on those library-specific symbols in the patterns being tested for.
42ddaab
to
d849c8f
Compare
With diffblue#6590, several unnecessary symbols are no longer included in goto programs. These include unbounded arrays, which the incremental SMT back-end hitherto does not support. The use of --slice-formula was a workaround to make sure the unnecessary symbols (or equalities over them) don't end up in the formula; now they aren't part of the goto program, so the workaround no longer adds value.
With diffblue#6590, several unnecessary symbols are no longer included in goto programs. These include unbounded arrays, which the incremental SMT back-end hitherto does not support. The use of --slice-formula was a workaround to make sure the unnecessary symbols (or equalities over them) don't end up in the formula; now they aren't part of the goto program, so the workaround no longer adds value.
With diffblue#6590, several unnecessary symbols are no longer included in goto programs. These include unbounded arrays, which the incremental SMT back-end hitherto does not support. The use of --slice-formula was a workaround to make sure the unnecessary symbols (or equalities over them) don't end up in the formula; now they aren't part of the goto program, so the workaround no longer adds value.
With diffblue#6590, several unnecessary symbols are no longer included in goto programs. These include unbounded arrays, which the incremental SMT back-end hitherto does not support. The use of --slice-formula was a workaround to make sure the unnecessary symbols (or equalities over them) don't end up in the formula; now they aren't part of the goto program, so the workaround no longer adds value.
With diffblue#6590, several unnecessary symbols are no longer included in goto programs. These include unbounded arrays, which the incremental SMT back-end hitherto does not support. The use of --slice-formula was a workaround to make sure the unnecessary symbols (or equalities over them) don't end up in the formula; now they aren't part of the goto program, so the workaround no longer adds value.
The goal of this series of commits is to reduce the number of
__CPROVER_...
static-lifetime objects that appear in every program irrespective of their use by C (model) library functions. This will limit verification overhead to those cases where they are actually used. This will also enable more costly objects (such as unbounded arrays) to be used by future library instrumentation.