mipsisa32-unknown-elf-as: Error: too large constant specified
Thiemo Seufer
ica2_ts@csv.ica.uni-stuttgart.de
Wed Oct 15 12:49:00 GMT 2003
Alan Modra wrote:
> On Wed, Oct 15, 2003 at 01:03:11PM +0200, Thiemo Seufer wrote:
> > + if (ex->X_op == O_constant && HAVE_32BIT_GPRS)
> > + {
> > + if (ex->X_add_number < 0)
> > + ex->X_add_number = ((ex->X_add_number + 0x80000000) & 0xffffffff)
> > + - 0x80000000;
> > + else
> > + ex->X_add_number &= 0xffffffff;
> > + }
>
> Better:
>
> if (ex->X_op == O_constant && HAVE_32BIT_GPRS)
> ex->X_add_number = (((ex->X_add_number & 0xffffffff) ^ 0x80000000)
> - 0x80000000);
I don't want to sign-extend it. I want to discard the high bits.
Thiemo
More information about the Binutils
mailing list