Alias changes

Mark Mitchell
Thu Jun 25 11:05:00 GMT 1998

>>>>> "Jeffrey" == Jeffrey A Law <> writes:

    Jeffrey>   In message
    Jeffrey> < >you write: I
    Jeffrey> think we need to save/restore the current alias set # as
    Jeffrey> we change function contexts so that the current alias set
    Jeffrey> # isn't scrogged when we compile a nested function.  Even
    Jeffrey> if this isn't an issue right now we need to go ahead and
    Jeffrey> save/restore the set #.  It's simple to do, so I don't
    Jeffrey> think you need to resubmit after making this change.
    >>  I don't quite get this.  With my patch, the C front-end
    >> assigns alias sets to types lazily, as it creates MEMs who need
    >> alias sets.  It doesn't make sense to have different types in
    >> the same alias set, so I don't see why we'd ever want to
    >> restore the alias set counter to a previous value.  It should
    >> monotonically increase, I think.
    Jeffrey> Do they monotonically increase through a function or
    Jeffrey> through an entire compilation unit.

    Jeffrey> If the former, then we need to save/restore as we change
    Jeffrey> function contexts.  If the latter, then we do not need to
    Jeffrey> save/restore it.

The latter.  For example, alias sets are assigned to global variables,
and we must be sure that their alias sets continue to make sense.

    Jeffrey> jeff

Mark Mitchell
Mark Mitchell Consulting

More information about the Gcc-patches mailing list