sizetype, bitsizetype and DECL_FIELD_BITPOS

Joern Rennecke amylaar@cygnus.co.uk
Fri Dec 31 23:54:00 GMT 1999


>     size_binop is supposed to convert to sizetype.
> 
> In which cases?  Surely it can't convert both of its args unconditionally to
> sizetype since it's called to do an EXACT_DIV_EXPR of a bitsizetype value by
> BITS_PER_UNIT.  That division has to be in bitsizetype.  And in that case the
> BITS_PER_UNIT also needs to be bitsizetype, while it's currently sizetype.
> Moreover, in a number of cases, the WITH_RECORD_EXPR that's being made is
> also the wrong type (sizetype instead of bitsizetype).

I read the comment that size_binop is supposed to convert the result
to sizetype.

If size_binop required all inputs and the output to be the same type, it
should just get the result type from one of the arguments, and be called
tree_binop or something similarily type-independent.



More information about the Gcc mailing list