Skip to content

Conversation

asgerf
Copy link
Contributor

@asgerf asgerf commented Feb 1, 2024

Fixes a bug in the handling of stateful out-barriers.

These were initially handled at the very last pruning step, since they aren't relevant for pruning in practice.

However, subpaths is computed in a way that isn't affected by the pruning, whereas edges is affected. This can result in a tuple subpaths(arg, par, ret, res) where edges*(par, ret) does not hold.

This means we get a spurious arg -> res edge, which can result in a spurious alert. And this alert is missing its data flow path, because no path can be materialised for par -> ret.

The solution I've opted for is just to check the out-barrier when we generate the steps that feed into pathStep. I've verified (for one query) that when stateful out-barriers aren't in use, the DIL is unaffected.

@asgerf asgerf added the no-change-note-required This PR does not need a change note label Feb 12, 2024
@asgerf asgerf marked this pull request as ready for review February 12, 2024 10:14
@asgerf asgerf requested a review from a team as a code owner February 12, 2024 10:14
Copy link
Contributor

@aschackmull aschackmull left a comment

Choose a reason for hiding this comment

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

LGTM

@asgerf asgerf merged commit faefa05 into github:main Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DataFlow Library Java no-change-note-required This PR does not need a change note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants