Skip to content

Function pointer removal: argument conversion must use byte extract #6959

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

Conversation

tautschnig
Copy link
Collaborator

Only POD can be handled via type casts, all other cases require
reinterpreting the byte sequence. For POD, the simplifier will clean up
the byte extract.

The same problem had already been fixed for goto-symex' function
argument conversion back in bb80cdc.

Co-authored-by: Celina G. Val [email protected]

Fixes: #6956

  • Each commit message has a non-empty body, explaining why the change was made.
  • n/a Methods or procedures I have added are documented, following the guidelines provided in CODING_STANDARD.md.
  • n/a The feature or user visible behaviour I have added or modified has been documented in the User Guide in doc/cprover-manual/
  • Regression or unit tests are included, or existing tests cover the modified code (in this case I have detailed which ones those are in the commit message).
  • n/a My commit message includes data points confirming performance improvements (if claimed).
  • My PR is restricted to a single feature or bugfix.
  • n/a White-space or formatting changes outside the feature-related changed lines are in commits of their own.

@peterschrammel peterschrammel removed their assignment Jun 23, 2022
@tautschnig tautschnig assigned tautschnig and unassigned kroening Jun 23, 2022
Only POD can be handled via type casts, all other cases require
reinterpreting the byte sequence. For POD, the simplifier will clean up
the byte extract.

The same problem had already been fixed for goto-symex' function
argument conversion back in bb80cdc.

Co-authored-by: Celina G. Val <[email protected]>

Fixes: diffblue#6956
@codecov
Copy link

codecov bot commented Jun 23, 2022

Codecov Report

Merging #6959 (e4d7411) into develop (b5ab3a1) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff            @@
##           develop    #6959   +/-   ##
========================================
  Coverage    77.79%   77.79%           
========================================
  Files         1568     1568           
  Lines       180347   180350    +3     
========================================
+ Hits        140309   140312    +3     
  Misses       40038    40038           
Impacted Files Coverage Δ
jbmc/src/janalyzer/janalyzer_parse_options.cpp 48.58% <ø> (ø)
src/goto-analyzer/goto_analyzer_parse_options.cpp 72.27% <ø> (ø)
src/goto-programs/remove_function_pointers.cpp 92.79% <100.00%> (+0.09%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a0d4239...e4d7411. Read the comment docs.

@tautschnig tautschnig force-pushed the bugfixes/function-pointer-arg-conversion branch from 7fd705a to e4d7411 Compare June 23, 2022 08:44
@tautschnig tautschnig merged commit 73c10c3 into diffblue:develop Jun 23, 2022
@tautschnig tautschnig deleted the bugfixes/function-pointer-arg-conversion branch June 23, 2022 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistent casting results for nested structures
3 participants