This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
steakhal marked 2 inline comments as done.
Closed by commit rGa80418eec001: [analyzer] Improve loads from reinterpret-cast
fields (authored by steakhal).
Changed prior
martong accepted this revision.
martong added a comment.
This revision is now accepted and ready to land.
LGTM (given that you remove the vague and disturbing FIXME comments).
Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:2014-2017
+ // FIXME: This is a hack, and d
steakhal added inline comments.
Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:1897
+ QualType Ty = SubReg->getValueType();
+ if (BaseTy->isScalarType() && Ty->isScalarType()) {
+if (Ctx.getTypeSizeInChars(BaseTy) >= Ctx.getTypeSizeInChars(Ty)) {
martong added a comment.
I like it, but I'd like to know more about the nature of the applied "hack" and
if there is a way to solve it properly in the longer term.
Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:2014-2017
+ // FIXME: This is a hack, and doesn't do a
steakhal added a comment.
No runtime diff. No crashes.
8 disappeared:
- 4 core.CallAndMessage (1st arg is uninitialized)
- 2 alpha.deadcode.UnreachableCode (sinked before reaching it)
- 2 core.UndefinedBinaryOperatorResult
2 new reports:
- 1 core.UndefinedBinaryOperatorResult
- 1 alpha.security
steakhal created this revision.
steakhal added reviewers: NoQ, martong, ASDenysPetrov.
Herald added subscribers: manas, dkrupp, donat.nagy, Szelethus,
mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun.
Herald added a reviewer: Szelethus.
Herald added a project: All.
steak