[PATCH] D12726: [analyzer] A fix for symbolic element region index lifetime.

Artem Dergachev via cfe-commits cfe-commits at lists.llvm.org
Mon Dec 7 02:02:10 PST 2015


NoQ added a comment.

In http://reviews.llvm.org/D12726#303122, @zaks.anna wrote:

> > So the real question is whether (or rather how) the Store should maintain correct region liveness information 
>
> >  after completing its internal garbage collection pass, because there are, in fact, other users of 
>
> >  this information later in the chain, but this seems to be a larger problem without instantly noticeable effects.
>
>
> Could you give specific (possibly potential) examples of this problem?
>
> We assume that the symbols that are collected do not need to stick around, so no-one "later in the chain" should need them. Except for the cases where we artificially extend liveness by calling addSymbolDependency().


What I was trying to say is that after `StoreManager` iterates over the `Store`, there are also checkers that may want to make decisions on liveness of their symbols based on liveness of certain regions, by checking `SymbolReaper::isLiveRegion()`, but currently such behavior is very rare, and thus barely tested. But eventually, with more checkers and further development, we'd need to figure out how this should work (eg. http://reviews.llvm.org/D14277 is a step in this direction - this patch can only work as long as `isLiveRegion()` is reliable after GC'ing the `Store`). Theoretically, it still makes sense to me to say that, for example, the `Store` shouldn't hold its keys as live - for the reasons stated above.

So this is mostly a hand-waving thing, and i think the patch is not immediately affected by this potential debate, and it should be OK to commit it.


http://reviews.llvm.org/D12726





More information about the cfe-commits mailing list