https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89270

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rguenth at gcc dot gnu.org
   Target Milestone|---                         |9.0

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Not sure, but possibly not returning false here:

static bool
verify_gimple_assign_unary (gassign *stmt)
{
..
        /* Allow conversions from pointer type to integral type only if
           there is no sign or zero extension involved.
           For targets were the precision of ptrofftype doesn't match that
           of pointers we need to allow arbitrary conversions to ptrofftype. 
*/
        if ((POINTER_TYPE_P (lhs_type)
             && INTEGRAL_TYPE_P (rhs1_type))
            || (POINTER_TYPE_P (rhs1_type)
                && INTEGRAL_TYPE_P (lhs_type)
                && (TYPE_PRECISION (rhs1_type) >= TYPE_PRECISION (lhs_type)
                    || ptrofftype_p (lhs_type))))
          return false;

elsewhere I suggested that instead of special-casing ptrofftype_p we need
this special case only if POINTERS_EXTEND_UNSIGNED is defined and for
Pmode and word_mode lhs_type mode.

Not sure how named address-spaces are handled here since
POINTERS_EXTEND_UNSIGNED
doesn't talk about them.

Reply via email to