This is the mail archive of the
mailing list for the GCC project.
RE: [PATCH] Use rtx_refs_may_alias_p instead of alias_sets_conflict_p in
On Wed, 4 Aug 2010, Bingfeng Mei wrote:
> Does rtx_refs_may_alias_p include offset based disambiguation (with/without
> tbaa flag).
Actually it doesn't (we switch off recognizing SSA names as being equal
when called from RTL land). I forgot that this was recently changed.
Unfortunately I was wrong with my assertion that TBAA can be used cross
iteration. The catch is the new memory model, with it's asymmetric
dependencies: you may move a load before a non-conflicting (type
wise) store, but you may not move a store before a non-conflicting load.
In cross-iteration situations you are posed with both cases, hence you
can't really use type-based disambiguation (perhaps in some few special
cases one might, but not generally).
Basically for cross iteration analysis you can only use points-to
information (or generally everything that is loop invariant for the loop
in question, but that isn't implemented).
> If yes, this patch is not correct, I need to work out a better one.
It would be better to use the four different predicates we have in RTL
land as Richard suggested, they do the right thing for each dependency
type (switching off TBAA when appropriate).