This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: Add a builtin define for when the floating point registersare not available

Hi Aldy,

You are right of course. Further testing of the patch showed me that I needed this anyway, so imagine if you will that I had submitted the patch with an identical change to gcc/config/rs6000/linux.h. :-)

How about you put it in rs6000_override_options, and only do it once?

Good idea, although I think that maybe rs6000_cpu_cpp_builtins() might be a better place, so what do you think of this alternative patch ?


2005-05-23  Nick Clifton  <>

	* config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Define
	__NO_FPRS__ when 'f' class registers will not be available.

Index: gcc/config/rs6000/rs6000-c.c
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/rs6000-c.c,v
retrieving revision 1.17
diff -c -3 -p -r1.17 rs6000-c.c
*** gcc/config/rs6000/rs6000-c.c	2 May 2005 16:02:44 -0000	1.17
--- gcc/config/rs6000/rs6000-c.c	23 May 2005 08:33:55 -0000
*************** rs6000_cpu_cpp_builtins (cpp_reader *pfi
*** 140,145 ****
--- 140,149 ----

+ /* Let the compiled code know if 'f' class registers will not be available. */
+ builtin_define ("__NO_FPRS__");
targetm.resolve_overloaded_builtin = altivec_resolve_overloaded_builtin;

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