This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


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

Re: Patch to add -mfp32 support to MIPS gas



> Tested on mips-elf. mipsel-elf and mips64-elf.  OK to apply?
> 

I think they are ok, but since there was discussion I'll give everyone
until tomorrow to object :)

Actually, you can use this time to document the options and include it
in your final patch :)

-eric

> 
> [gas/ChangeLog]
> 
> 	* tc-mips.c (mips_fp32, mips_32bit_abi): New static variables.
> 	(md_long_opts): Add -mfp32 option.
> 	(md_parse_option): Handle it.  Set mips_32bit_abi given -mabi=32.
> 	(md_show_usage): Show usage for -mfp32 and -mgp32.
> 	(HAVE_32BIT_GPRS, HAVE_32BIT_FPRS): New macros.
> 	(HAVE_64BIT_GPRS, HAVE_64BIT_FPRS): New macros, inverse of the above.
> 	(HAVE_32BIT_ADDRESSES): New macro.
> 	(load_register): Use HAVE_32BIT_GPRS to determine the register width.
> 	(load_address): Use HAVE_32BIT_ADDRESSES to determine the address size.
> 	(s_cprestore, s_cpadd): Likewise.
> 	(macro): Use HAVE_32BIT_GPRS to determine the width of registers
> 	used in branch and M_LI_D macros.  Use HAVE_64BIT_FPRS to determine
> 	the width registers used in M_LI_DD macros.  Use HAVE_32BIT_ADDRESSES
> 	to determine the width of addresses in load, store and jump macros.
> 	(macro2): Use HAVE_32BIT_GPRS to determine the width of registers
> 	used in set instructions; do not check the address size for them.
> 	Use HAVE_32BIT_ADDRESSES to determine the width of addresses in
> 	unaligned load and store macros.
> 	(mips_ip): Use the new macros to check the width of a register when
> 	processing float constants.  Force a constant into memory if it is
> 	destined for an FPR and the FPRs are wider than the GPRs.  Warn about
> 	odd FPR numbers if HAVE_32BIT_FPRS.
> 
> [gas/testsuite/ChangeLog]
> 
> 	* gas/mips/mips-gp32-fp32,
> 	* gas/mips/mips-gp32-fp64,
> 	* gas/mips/mips-gp64-fp32,
> 	* gas/mips/mips-gp64-fp64,
> 	* gas/mips/mips-abi32
> 	* gas/mips/mips-gp32-fp32-pic,
> 	* gas/mips/mips-gp32-fp64-pic,
> 	* gas/mips/mips-gp64-fp32-pic,
> 	* gas/mips/mips-gp64-fp64-pic,
> 	* gas/mips/mips-abi32-pic: New testcases.
> 
> 	* gas/mips/mips.exp: Run them.
> 

--
Look out behind you!


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