This repository has been archived by the owner on Aug 22, 2024. It is now read-only.
Fix problems with tag propagation from component to container #1142
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
When a tag with TagPropagation::SuperComponent is attached to a value which is a component of one or more other values, those other values also get tagged.
This is difficult to do in the heap model, not only because pointer indirections are unidirectional, but also because environments in callees are not filled in with information from their callers.
The work around for the latter problem is to delay tag checks whenever possible. The work around for the former problem is to not rely on the tag operation to do the full propagation. I.e. only when has_tag! is applied to a container, will a full recursive traversal of the heap model be done to see if any value that is reachable from the container root is tagged.
Fixes #1131
Type of change
How Has This Been Tested?
./validate.sh
CI