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: Fix processing of ADDR_EXPR in get_expr_operands


    No.  It is not a bug.  I don't know how else to tell you the same
    thing.  Address constness is checked with TREE_INVARIANT.  The address
    of a variable may be invariant in one invocation to a function, but have
    different values from call to call.

The two mean two different thing: "invariant" means it won't change during
the execution of the function while "constant" means it won't change *at all*.
I can easily see cases where the first is what's wanted and where the second
is what's wanted.  It may well be that in that particular case, "invariant"
is the wanted property, but I don't accept that that's *always* the case.

    Yes.  Overflow.

Why do we care about overflow?  If an addressing computation overflows, it's
still a constant!


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