Making more builtins fold-able, and handling side-effects in args

Richard Kenner kenner@vlsi1.ultra.nyu.edu
Mon Feb 5 15:46:00 GMT 2001


    > You should.  It's always best to have the tree as type-correct as
    > possible.

    Certainly types matter for PLUS_EXPR, but COMPOUND_EXPR?
    I don't think converting makes any sense there at all.
    
The type of a COMPOUND_EXPR matters since it might be the operand of a
PLUS_EXPR.  The type of the first operand should be the same as the
type of the COMPOUND_EXPR (so an optimizer could replace it with the
first operand if it could determine that the second operand does not
actually have any side effects). I agree the type of the second operand
does not matter.


More information about the Gcc mailing list