Skip to content

Java: Data-flow pruning based on call contexts.#2099

Merged
hvitved merged 20 commits intogithub:masterfrom
aschackmull:java/callcontext-bool-pruning
Oct 15, 2019
Merged

Java: Data-flow pruning based on call contexts.#2099
hvitved merged 20 commits intogithub:masterfrom
aschackmull:java/callcontext-bool-pruning

Conversation

@aschackmull
Copy link
Contributor

This is a continuation of #2011.

@aschackmull
Copy link
Contributor Author

Changes on https://jenkins.internal.semmle.com/job/Changes/job/Java-Differences/337/ looks good (I accidentally switched the shas, so the removed results are listed as added). Two FPs removed on jdk11.

@aschackmull aschackmull marked this pull request as ready for review October 11, 2019 12:21
@aschackmull aschackmull requested review from a team as code owners October 11, 2019 12:21
Copy link
Contributor

@hvitved hvitved left a comment

Choose a reason for hiding this comment

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

LGTM, just a few minor comments.

* Gets the local call context given the call context and the callable that
* the contexts apply to.
*/
LocalCallContext getLocalCallContext(CallContext ctx, DataFlowCallable callable) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Do you think it makes sense to cache this predicate?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It might. I don't think it's crucial, though.

)
}

/** An expression that always has the same boolean value. */
Copy link
Contributor

Choose a reason for hiding this comment

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

An expression -> A call argument

Copy link
Contributor

Choose a reason for hiding this comment

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

boolean -> Boolean (also below)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed.

@hvitved hvitved merged commit cae7f9d into github:master Oct 15, 2019
@aschackmull aschackmull deleted the java/callcontext-bool-pruning branch October 15, 2019 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants