This is an archive of the discontinued LLVM Phabricator instance.

[analyzer][solver] Fix infeasible constraints (PR49642)
ClosedPublic

Authored by vsavchenko on Mar 19 2021, 7:06 AM.

Details

Summary

Additionally, this patch puts an assertion checking for feasible
constraints in every place where constraints are assigned to states.

Diff Detail

Event Timeline

vsavchenko created this revision.Mar 19 2021, 7:06 AM
vsavchenko requested review of this revision.Mar 19 2021, 7:06 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 19 2021, 7:06 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript

Fix typos in comments

steakhal accepted this revision.Mar 19 2021, 10:31 AM

Aa, get it. Looks good.

This revision is now accepted and ready to land.Mar 19 2021, 10:31 AM
NoQ accepted this revision.Mar 19 2021, 3:08 PM

Aha ok, seems reasonable, thx!

clang/test/Analysis/PR49642.c
2

Why not the usual %clang_analyze_cc1? Your approach only adds driver testing which doesn't seem to test anything new. Also if you do clang --analyze you don't need to enable core explicitly, you already have all on-by-default checks running.

vsavchenko added inline comments.Mar 19 2021, 11:00 PM
clang/test/Analysis/PR49642.c
2

I didn't figure out how to reproduce the crash with %clang_analyze_cc1 :-(

NoQ added inline comments.Mar 20 2021, 1:30 PM
clang/test/Analysis/PR49642.c
2

Mmm ok weird. Let's start by using -### to convert the driver invocation into a -cc1 invocation and then bisecting flags until we obtain a minimal -cc1 invocation.

Re-write the test using %clang_analyze_cc1

vsavchenko marked an inline comment as done.Mar 22 2021, 1:01 AM
This revision was landed with ongoing or failed builds.Mar 22 2021, 1:02 AM
This revision was automatically updated to reflect the committed changes.