Skip to content
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

Not allowing disabling modeling checkers in ClangSA #3323

Merged
merged 1 commit into from
Feb 28, 2022

Conversation

dkrupp
Copy link
Member

@dkrupp dkrupp commented May 19, 2021

When a Clang Static Analyzer checker is disabled in CodeChecker, clang is invoked with the analyzer-disable-checker flag. This allows the user disabling core modeling checkers such as unix.DynamicMemoryModeling. This causes malfunctioning of depending checkers.

❗ ❗ ❗ Breaking Change: ❗ ❗ ❗
After this patch, modeling and debug checkers (listed with clang -cc1 -analyzer-checker-help-developer)
will not be listed and cannot be disabled through CodeChecker with the --enable and --disable flags.

They can be enabled/disabled through the Clang Static Analyzer specific --saargs flag only.

Copy link
Contributor

@csordasmarton csordasmarton left a comment

Choose a reason for hiding this comment

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

Github action test cases are failed. I think the problem is that this option is supported properly only by the latest clang. So we should handle this on a version dependent way.

@bruntib bruntib added this to the release 6.17.0 milestone Jun 30, 2021
@csordasmarton csordasmarton modified the milestones: release 6.17.0, release 6.17.1 Sep 7, 2021
@csordasmarton csordasmarton modified the milestones: release 6.17.1, release 6.18.0 Nov 4, 2021
@dkrupp dkrupp force-pushed the silencing branch 5 times, most recently from 3144cd0 to 79e50ed Compare February 22, 2022 12:18
@dkrupp dkrupp requested a review from csordasmarton February 23, 2022 08:40
@csordasmarton csordasmarton changed the title Silencing checkers Not allowing disabling modeling checkers in ClangSA Feb 24, 2022
Copy link
Contributor

@csordasmarton csordasmarton left a comment

Choose a reason for hiding this comment

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

There is a typo in the commit message: chekcers vs checkers. Please update the commit message.

@csordasmarton csordasmarton added this to the release 6.19.0 milestone Feb 24, 2022
@csordasmarton csordasmarton added analyzer 📈 Related to the analyze commands (analysis driver) WARN ⚠️: Backward compatibility breaker! MIND THE GAP! Merging this patch will mess up compatibility with the previous releases! config ⚙️ labels Feb 24, 2022
@dkrupp dkrupp requested a review from csordasmarton February 25, 2022 14:30
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
docs/analyzer/checker_and_analyzer_configuration.md Outdated Show resolved Hide resolved
When a Clang Static Analyzer checker is disabled in CodeChecker,
clang is invoked with the "analyzer-disable-checker" flag.
This allows the user disabling core modeling checkers such as
unix.DynamicMemoryModeling. This causes malfunctioning of depending checkers.

Breaking Change:
After this patch, modeling and debug checkers (listed with clang -cc1 -analyzer-checker-help-developer)
will not be listed and cannot be disabled through CodeChecker with the --enable and --disable flags.

They can be enabled/disabled through the Clang Static Analyzer specific --saargs flag only.
@dkrupp
Copy link
Member Author

dkrupp commented Feb 28, 2022

Thanks for the review. All comments fixed.

Copy link
Contributor

@csordasmarton csordasmarton left a comment

Choose a reason for hiding this comment

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

LGTM!

@csordasmarton csordasmarton merged commit efeb473 into Ericsson:master Feb 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyzer 📈 Related to the analyze commands (analysis driver) config ⚙️ WARN ⚠️: Backward compatibility breaker! MIND THE GAP! Merging this patch will mess up compatibility with the previous releases!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants