public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* gcc/config/rs6000/rs6000.h bug?
@ 1998-07-17 18:50 Rask Ingemann Lambertsen
  1998-07-18  6:32 ` David Edelsohn
  0 siblings, 1 reply; 6+ messages in thread
From: Rask Ingemann Lambertsen @ 1998-07-17 18:50 UTC (permalink / raw)
  To: EGCS mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 883 bytes --]

   Hi.

   Around line 361, gcc/config/rs6000/sysv.h reads

----------
/* Use the regular svr4 definitions.  */

#include "svr4.h"
----------

thus making the assumption that all the PowerPC targets that use the System
V.4 ABI run the SVR4 OS. Is it really supposed to be like that?

Regards,

/¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯T¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯\
| Rask Ingemann Lambertsen       | E-mail: mailto:rask@kampsax.k-net.dk  |
| Registered Phase5 developer    | WWW: http://www.gbar.dtu.dk/~c948374/ |
| A4000, 775 kkeys/s (RC5-64)    | "ThrustMe" on XPilot, ARCnet and IRC  |
|               Es funktioniert nicht, sieht aber gut aus.               |


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gcc/config/rs6000/rs6000.h bug?
  1998-07-17 18:50 gcc/config/rs6000/rs6000.h bug? Rask Ingemann Lambertsen
@ 1998-07-18  6:32 ` David Edelsohn
  1998-07-18 11:59   ` Rask Ingemann Lambertsen
  0 siblings, 1 reply; 6+ messages in thread
From: David Edelsohn @ 1998-07-18  6:32 UTC (permalink / raw)
  To: Rask Ingemann Lambertsen; +Cc: EGCS mailing list

>>>>> "Rask Ingemann Lambertsen" writes:

Rask> ----------
Rask> /* Use the regular svr4 definitions.  */

Rask> #include "svr4.h"
Rask> ----------

Rask> thus making the assumption that all the PowerPC targets that use the System
Rask> V.4 ABI run the SVR4 OS. Is it really supposed to be like that?

	This only means that the PowerPC System V.4 configuration uses the
common GCC System %.4 configuration as a base -- not that it runs SVR4
OS.  It simply avoids defining and maintaining duplicative configuration
details.  

David

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gcc/config/rs6000/rs6000.h bug?
  1998-07-18  6:32 ` David Edelsohn
@ 1998-07-18 11:59   ` Rask Ingemann Lambertsen
  1998-07-20 17:25     ` David Edelsohn
  0 siblings, 1 reply; 6+ messages in thread
From: Rask Ingemann Lambertsen @ 1998-07-18 11:59 UTC (permalink / raw)
  To: David Edelsohn; +Cc: egcs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2191 bytes --]

Den 18-Jul-98 15:32:18 skrev David Edelsohn følgende om "Re: gcc/config/rs6000/rs6000.h bug? ":

> Rask> thus making the assumption that all the PowerPC targets that use the
> System Rask> V.4 ABI run the SVR4 OS. Is it really supposed to be like that?

> 	This only means that the PowerPC System V.4 configuration uses the
> common GCC System %.4 configuration as a base -- not that it runs SVR4
> OS.  It simply avoids defining and maintaining duplicative configuration
> details.  

Yes, sorry, I mixed up "gcc/config/rs6000/rs6000.h" with
"gcc/config/rs6000/xm-rs6000.h" and "gcc/config/svr4.h" with
"gcc/config/xm-svr4.h". And anyway, the offending #include "xm-svr4.h" isn't
there any longer in the CVS repository, so cheers for that.

This doesn't mean that I can't find something else to complain about, though.
;-)

A freshly checked out "gcc/config/rs6000/xm-rs6000.h" contains:

---------
/* Arguments to use with `exit'.  */
#define	SUCCESS_EXIT_CODE	0
#define	FATAL_EXIT_CODE		33
---------

which should be removed since <stdlib.h> already define them (and even to
correct values). At least they should be protected by #ifndef, but they are
not Power(PC) specific and thus don't belong here. But wait, there's more:

----------
/* AIX is a flavor of System V */
#define	USG
----------

and

----------
#ifndef CROSS_COMPILE
/* The AIX linker will discard static constructors in object files before
   collect has a chance to see them, so scan the object files directly.  */
#define COLLECT_EXPORT_LIST
#endif
----------

which IMHO belongs in xm-aix??.h, not in xm-rs6000.h.

Regards,

/¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯T¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯\
| Rask Ingemann Lambertsen       | E-mail: mailto:rask@kampsax.k-net.dk  |
| Registered Phase5 developer    | WWW: http://www.gbar.dtu.dk/~c948374/ |
| A4000, 775 kkeys/s (RC5-64)    | "ThrustMe" on XPilot, ARCnet and IRC  |
| Keyboard error: <Ctrl> and <Alt> are stuck - press <Del> to continue   |


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gcc/config/rs6000/rs6000.h bug?
  1998-07-18 11:59   ` Rask Ingemann Lambertsen
@ 1998-07-20 17:25     ` David Edelsohn
  1998-08-27  7:40       ` Rask Ingemann Lambertsen
  0 siblings, 1 reply; 6+ messages in thread
From: David Edelsohn @ 1998-07-20 17:25 UTC (permalink / raw)
  To: Rask Ingemann Lambertsen; +Cc: egcs

>>>>> "Rask Ingemann Lambertsen" writes:

Rask> A freshly checked out "gcc/config/rs6000/xm-rs6000.h" contains:

Rask> ---------
Rask> /* Arguments to use with `exit'.  */
Rask> #define	SUCCESS_EXIT_CODE	0
Rask> #define	FATAL_EXIT_CODE		33
Rask> ---------

Rask> which should be removed since <stdlib.h> already define them (and even to
Rask> correct values).

	The values in xm-rs6000.h only are used by the GCC compiler itself
-- not exported, so why does this matter?  Historically GCC has wanted a
distinct failure value exit status.

Rask> ----------
Rask> /* AIX is a flavor of System V */
Rask> #define	USG
Rask> ----------

Rask> and

Rask> ----------
Rask> #ifndef CROSS_COMPILE
Rask> /* The AIX linker will discard static constructors in object files before
Rask> collect has a chance to see them, so scan the object files directly.  */
Rask> #define COLLECT_EXPORT_LIST
Rask> #endif
Rask> ----------

Rask> which IMHO belongs in xm-aix??.h, not in xm-rs6000.h.

	xm-rs6000.h only is used for AIX.  This is a historical artifact
from the "rs6000" port originally only targeted for AIX.  This also is why
the port is called "rs6000" instead of something more appropriate.  All of
this is hidden from the user in the GCC configuration, so, again, why does
this matter?

	GCC developers do not make gratuitous changes to fix things which
really are not broken.  xm-rs6000.h is the default because the port is
called "rs6000".  AIX is in some sense the default target for that port.
If we change this name then we need to manually add "xm-aix.h" throughout
which could introduce errors.  I don't consider changing internal APIs for
beauty to be good software engineering practice.  This is not what would
be used if we were starting from scratch, but this is what we have
inherited.

David


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gcc/config/rs6000/rs6000.h bug?
  1998-07-20 17:25     ` David Edelsohn
@ 1998-08-27  7:40       ` Rask Ingemann Lambertsen
  1998-09-25 19:05         ` David Edelsohn
  0 siblings, 1 reply; 6+ messages in thread
From: Rask Ingemann Lambertsen @ 1998-08-27  7:40 UTC (permalink / raw)
  To: EGCS mailing list

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1737 bytes --]

Den 20-Jul-98 22:56:21 skrev David Edelsohn følgende om "Re: gcc/config/rs6000/rs6000.h bug? ":
>>>>>> "Rask Ingemann Lambertsen" writes:

> Rask> A freshly checked out "gcc/config/rs6000/xm-rs6000.h" contains:
[cut]
> Rask> which IMHO belongs in xm-aix??.h, not in xm-rs6000.h.

> 	xm-rs6000.h only is used for AIX.  This is a historical artifact
> from the "rs6000" port originally only targeted for AIX.

   It would be nice to have a note to that effect. How about:

--- /dev/null   Thu Jan  1 01:00:00 1970
+++ config/rs6000/README        Thu Aug 27 13:47:35 1998
@@ -0,0 +1,2 @@
+xm-rs6000.h is only used for AIX. This is a historical artifact
+from the "rs6000" port originally only targeted for AIX.


   And for Changelog:

Thu Aug 27 13:37:44 1998  Rask Ingemann Lambertsen <rask@kampsax.k-net.dk>

    * config/rs6000/README: New file

> This also is why
> the port is called "rs6000" instead of something more appropriate.  All of
> this is hidden from the user in the GCC configuration, so, again, why does
> this matter?

   Not for the end user, but it is confusing for those who try to add a new
PowerPC based target.

Regards,

/¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯T¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯\
| Rask Ingemann Lambertsen       | E-mail: mailto:rask@kampsax.k-net.dk  |
| Registered Phase5 developer    | WWW: http://www.gbar.dtu.dk/~c948374/ |
| A4000, 775 kkeys/s (RC5-64)    | "ThrustMe" on XPilot, ARCnet and IRC  |
|                           LOAD "emacs",8,1                             |


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gcc/config/rs6000/rs6000.h bug?
  1998-08-27  7:40       ` Rask Ingemann Lambertsen
@ 1998-09-25 19:05         ` David Edelsohn
  0 siblings, 0 replies; 6+ messages in thread
From: David Edelsohn @ 1998-09-25 19:05 UTC (permalink / raw)
  To: Rask Ingemann Lambertsen; +Cc: EGCS mailing list

>>>>> "Rask Ingemann Lambertsen" writes:

>> xm-rs6000.h only is used for AIX.  This is a historical artifact
>> from the "rs6000" port originally only targeted for AIX.

Rask> It would be nice to have a note to that effect. 

	This use of the file is fairly clear in the comment at the top
that it is for "IBM RS/6000" which is a specific IBM product, not generic
for an architecture or the entire port.  I have extended the comment to
say "running AIX in 32-bit mode" to make this abundantly clear.  A README
file in the directory explaining this usage, the filename, and the whole
history of the name for the port in more detail is unnecessary and simply
will add clutter.

David

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1998-09-25 19:05 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-07-17 18:50 gcc/config/rs6000/rs6000.h bug? Rask Ingemann Lambertsen
1998-07-18  6:32 ` David Edelsohn
1998-07-18 11:59   ` Rask Ingemann Lambertsen
1998-07-20 17:25     ` David Edelsohn
1998-08-27  7:40       ` Rask Ingemann Lambertsen
1998-09-25 19:05         ` David Edelsohn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).