Skip to content

Restore member-of-union expressions in trace output #5633

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

Merged
merged 1 commit into from
Nov 5, 2022

Conversation

tautschnig
Copy link
Collaborator

byte_extract operations precisely capture the semantics, but aren't
meaningful to users.

  • 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.

@codecov
Copy link

codecov bot commented Nov 25, 2020

Codecov Report

Base: 77.89% // Head: 77.89% // Increases project coverage by +0.00% 🎉

Coverage data is based on head (fafe838) compared to base (8115bb9).
Patch coverage: 82.35% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #5633   +/-   ##
========================================
  Coverage    77.89%   77.89%           
========================================
  Files         1616     1616           
  Lines       186791   186834   +43     
========================================
+ Hits        145498   145538   +40     
- Misses       41293    41296    +3     
Impacted Files Coverage Δ
.../src/java_bytecode/java_bytecode_convert_class.cpp 94.18% <ø> (ø)
...src/java_bytecode/java_bytecode_convert_method.cpp 97.69% <ø> (ø)
jbmc/src/java_bytecode/java_bytecode_language.cpp 92.81% <ø> (ø)
jbmc/src/java_bytecode/java_object_factory.cpp 94.40% <ø> (ø)
jbmc/src/java_bytecode/java_string_literals.cpp 94.54% <ø> (ø)
src/analyses/cfg_dominators.h 100.00% <ø> (ø)
...le-sensitivity/value_set_pointer_abstract_object.h 100.00% <ø> (ø)
src/ansi-c/ansi_c_convert_type.h 100.00% <ø> (ø)
src/ansi-c/ansi_c_internal_additions.cpp 90.12% <ø> (ø)
src/ansi-c/c_typecheck_base.h 100.00% <ø> (ø)
... and 43 more

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.
📢 Do you have feedback about the report comment? Let us know in this issue.

@kroening
Copy link
Member

It seems a bit odd to do the 'restoring' in the output of a trace; wouldn't it be better to do that when that is built?

@tautschnig
Copy link
Collaborator Author

It seems a bit odd to do the 'restoring' in the output of a trace; wouldn't it be better to do that when that is built?

Indeed! I have reworked this, the patch is much smaller now.

@tautschnig tautschnig force-pushed the union-restore branch 2 times, most recently from bdd16b3 to c04f183 Compare November 26, 2020 21:22
@@ -117,6 +117,7 @@ class goto_trace_stept
// for assume, assert, goto
bool cond_value;
exprt cond_expr;
exprt original_condition;

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The difference between original_condition and cond_expr is non-obvious, and does deserve a comment.
Do we really need both?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was tempted to just re-purpose cond_expr, but it turns out it is actually used by goto-checker/bmc_util.cpp (I believe that is the only use). cond_expr is the SSA-renamed expression, while we'd want to provide an expression that is meaningful to the user. So maybe adding a comment is the right approach?

@tautschnig tautschnig force-pushed the union-restore branch 2 times, most recently from 3aa8906 to c3ebf1e Compare May 7, 2021 12:31
@tautschnig tautschnig force-pushed the union-restore branch 2 times, most recently from aa78d33 to 753d424 Compare September 28, 2022 10:28
@tautschnig tautschnig self-assigned this Oct 4, 2022
byte_extract operations precisely capture the semantics, but aren't
meaningful to users.
@peterschrammel peterschrammel removed their assignment Nov 5, 2022
@tautschnig tautschnig merged commit 5d4f090 into diffblue:develop Nov 5, 2022
@tautschnig tautschnig deleted the union-restore branch November 5, 2022 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants