summaryrefslogtreecommitdiff
path: root/lib/msan/msan_origin.h
AgeCommit message (Collapse)Author
2015-02-26[msan] Fix MsanTest to pass in track_origins=2 mode.Evgeniy Stepanov
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@230639 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-03[msan] Change the way origin ids are built.Evgeniy Stepanov
Previously, all origin ids were "chained" origins, i.e values of ChainedOriginDepot. This added a level of indirection for simple stack and heap allocation, which were represented as chains of length 1. This costs both RAM and CPU, but provides a joined 2**29 origin id space. It also made function (any instrumented function) entry non-async-signal-safe, but that does not really matter because memory stores in track-origins=2 mode are not async-signal-safe anyway. With this change, the type of the origin is encoded in origin id. See comment in msan_origin.h for more details. This reduces chained and stack origin id range to 2**28 each, but leaves extra 2**31 for heap origins. This change should not have any user-visible effects. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@223233 91177308-0d34-0410-b5e6-96231b3b80d8
2014-06-06[msan] Better diagnostic for invalid origin id.Evgeniy Stepanov
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@210331 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-21[msan] Chained origins re-design.Evgeniy Stepanov
Generalize StackDepot and create a new specialized instance of it to efficiently (i.e. without duplicating stack trace data) store the origin history tree. This reduces memory usage for chained origins roughly by an order of magnitude. Most importantly, this new design allows us to put two limits on stored history data (exposed in MSAN_OPTIONS) that help avoid exponential growth in used memory on certain workloads. See comments in lib/msan/msan_origin.h for more details. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@209284 91177308-0d34-0410-b5e6-96231b3b80d8