aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
diff options
context:
space:
mode:
authorKristóf Umann <dkszelethus@gmail.com>2021-07-05 15:11:46 +0200
committerKristóf Umann <dkszelethus@gmail.com>2021-08-16 16:19:00 +0200
commit2d3668c997faac1f64cd3b8eb336af989069d135 (patch)
tree12b8e73dcfb8ca6d18c51df6535294ac75568ad1 /llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
parent54a61c94f932f894f2695e0c18bb288d2d1407b7 (diff)
downloadllvm-2d3668c997faac1f64cd3b8eb336af989069d135.zip
llvm-2d3668c997faac1f64cd3b8eb336af989069d135.tar.gz
llvm-2d3668c997faac1f64cd3b8eb336af989069d135.tar.bz2
[analyzer] MallocChecker: Add a visitor to leave a note on functions that could have, but did not change ownership on leaked memory
This is a rather common feedback we get from out leak checkers: bug reports are really short, and are contain barely any usable information on what the analyzer did to conclude that a leak actually happened. This happens because of our bug report minimizing effort. We construct bug reports by inspecting the ExplodedNodes that lead to the error from the bottom up (from the error node all the way to the root of the exploded graph), and mark entities that were the cause of a bug, or have interacted with it as interesting. In order to make the bug report a bit less verbose, whenever we find an entire function call (from CallEnter to CallExitEnd) that didn't talk about any interesting entity, we prune it (click here for more info on bug report generation). Even if the event to highlight is exactly this lack of interaction with interesting entities. D105553 generalized the visitor that creates notes for these cases. This patch adds a new kind of NoStateChangeVisitor that leaves notes in functions that took a piece of dynamically allocated memory that later leaked as parameter, and didn't change its ownership status. Differential Revision: https://reviews.llvm.org/D105553
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp')
0 files changed, 0 insertions, 0 deletions