This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: alias.c:nonoverlapping_component_refs_p


On Mon, Dec 03, 2001 at 04:34:19PM -0500, Richard Kenner wrote:
> I believe you are right: this can occur even in C, though a more common
> example is bit fields: two MEMs made for accesses to two different bits in
> the same byte will certainly alias, but this code will say they won't.

No it won't.  I check for DECL_BIT_FIELD and do not apply
this optimization then.

At the same place, I also note that we can derive some information
if we make some assumptions about which bits insert/extract_bit_field
will touch for a given field.  For instance, it's unlikely that a
bit at position 0 will be manipulated concurrently with a bit at
position 1000, and in general I'd suspect (but don't know for sure)
that we could bound the check by bit_position/bits_per_word being
equal.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]