* i386-rtems(i386-coff) failure in egcs-19980628
@ 1998-07-06 14:48 Joel Sherrill
1998-07-07 5:29 ` Robert Lipe
0 siblings, 1 reply; 4+ messages in thread
From: Joel Sherrill @ 1998-07-06 14:48 UTC (permalink / raw)
To: egcs
version: egcs-19980628
host: RedHat Linux 5.0 (i686-pc-linux-gnu)
target: i386-rtems (based on i386-coff)
(NOTE: i386-rtemself has built successfully)
The failure occured while compiling __floatdidf from libgcc2.c. The
command line fragement is (some line continuations are mine):
/usr1/rtems/work/tools/build-i386-tools/gcc/xgcc \
-B/usr1/rtems/work/tools/build-i386-tools/gcc/ -O2 \
-DCROSS_COMPILE -DIN_GCC -O2 -g -I./include -g1 -DIN_LIBGCC2 \
-D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I../../src/gcc \
-I../../src/gcc/config -c -DL${name} \
../../src/gcc/libgcc2.c -o ${name}.o; \
if [ $? -eq 0 ] ; then true; else exit 1; fi; \
/usr1/rtems/work/tools/build-i386-tools/binutils/ar rc \
tmplibgcc2.a ${name}.o; \
rm -f ${name}.o; \
And the error message is:
_floatdidf
/tmp/ccekaQTS: Assembler messages:
/tmp/ccekaQTS:112: Error: Alignment not a power of 2
gmake[1]: *** [libgcc2.a] Error 1
gmake[1]: Leaving directory `/usr1/rtems/work/tools/build-i386-tools/gcc'
gmake: *** [all-gcc] Error 2
Suggestions appreciated.
--joel
Joel Sherrill Director of Research & Development
joel@OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (205) 722-9985
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: i386-rtems(i386-coff) failure in egcs-19980628
1998-07-06 14:48 i386-rtems(i386-coff) failure in egcs-19980628 Joel Sherrill
@ 1998-07-07 5:29 ` Robert Lipe
1998-07-07 10:14 ` Joel Sherrill
0 siblings, 1 reply; 4+ messages in thread
From: Robert Lipe @ 1998-07-07 5:29 UTC (permalink / raw)
To: Joel Sherrill, egcs
> version: egcs-19980628
> host: RedHat Linux 5.0 (i686-pc-linux-gnu)
> target: i386-rtems (based on i386-coff)
> (NOTE: i386-rtemself has built successfully)
Ha! It's not that I enjoy seeing you specifically suffer, Joel. It's
just that I welcome somebody else into x86 assembler "what do you mean
everything isn't linux?" hell. :-)
It took me a couple of builds to duplicate this and I think I've spotted
the offending code. However, I have little idea what the _best_
solution to this is.
> The failure occured while compiling __floatdidf from libgcc2.c. The
[ munch ]
> _floatdidf
> /tmp/ccekaQTS: Assembler messages:
> /tmp/ccekaQTS:112: Error: Alignment not a power of 2
I was able to duplicate this only with the GNU assembler, but I see
it fail on OSR5, too. i386-coff suffers from the same failure and
has slightly fewer config files in the way. Fortunately, OSR5 is
immune from this, but I couldn't at all point to sco5.h as a model for
anything.
For i386-coff, ultimately i386/gas.h gets included. This combination of
targets won't define ASM_OUTPUT_ALIGN, so we get the default one - the
one that says the argument to .align is the power of 2 we should pad to,
not the number of bytes that we should pad to.
This patch is absolutely wrong and should not be committed. It will,
I believe, get you going again, Joel.
If you'd like to fix only (and specifically) the rtems target, you might
think about cabbaging the definition and comments for ASM_OUTPUT_ALIGN
and stuffing them into i386-rtems.h. I think that'll get you going.
The comment about recent GAS versions sounds like somehing you should
note.
This is too sticky for me. I don't know the preferred way to make
a common file like gas.h know which of the conventions are used. I
suppose it could be autoconfiscated...
Index: gas.h
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/config/i386/gas.h,v
retrieving revision 1.3
diff -u -p -r1.3 gas.h
--- gas.h 1998/05/21 19:12:18 1.3
+++ gas.h 1998/07/07 04:38:49
@@ -80,7 +80,7 @@ Boston, MA 02111-1307, USA. */
doubt or guess work, and since this file is used for both a.out and other
file formats, we use one of them. */
-#if 0 /* ??? However, not every port uses binutils 2.6 yet. */
+#if 1 /* ??? However, not every port uses binutils 2.6 yet. */
#undef ASM_OUTPUT_ALIGN
#define ASM_OUTPUT_ALIGN(FILE,LOG) \
if ((LOG)!=0) fprintf ((FILE), "\t.balign %d\n", 1<<(LOG))
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: i386-rtems(i386-coff) failure in egcs-19980628
1998-07-07 5:29 ` Robert Lipe
@ 1998-07-07 10:14 ` Joel Sherrill
1998-07-09 0:27 ` Jeffrey A Law
0 siblings, 1 reply; 4+ messages in thread
From: Joel Sherrill @ 1998-07-07 10:14 UTC (permalink / raw)
To: Robert Lipe; +Cc: egcs
On Tue, 7 Jul 1998, Robert Lipe wrote:
> > version: egcs-19980628
> > host: RedHat Linux 5.0 (i686-pc-linux-gnu)
> > target: i386-rtems (based on i386-coff)
> > (NOTE: i386-rtemself has built successfully)
>
> Ha! It's not that I enjoy seeing you specifically suffer, Joel. It's
> just that I welcome somebody else into x86 assembler "what do you mean
> everything isn't linux?" hell. :-)
And everything i386 based is not a PC. :)
> It took me a couple of builds to duplicate this and I think I've spotted
> the offending code. However, I have little idea what the _best_
> solution to this is.
I have a proposal below for i386-coff and i386-rtems.
> > The failure occured while compiling __floatdidf from libgcc2.c. The
> [ munch ]
> > _floatdidf
> > /tmp/ccekaQTS: Assembler messages:
> > /tmp/ccekaQTS:112: Error: Alignment not a power of 2
>
> I was able to duplicate this only with the GNU assembler, but I see
> it fail on OSR5, too. i386-coff suffers from the same failure and
> has slightly fewer config files in the way. Fortunately, OSR5 is
> immune from this, but I couldn't at all point to sco5.h as a model for
> anything.
:(
> For i386-coff, ultimately i386/gas.h gets included. This combination of
> targets won't define ASM_OUTPUT_ALIGN, so we get the default one - the
> one that says the argument to .align is the power of 2 we should pad to,
> not the number of bytes that we should pad to.
>
> This patch is absolutely wrong and should not be committed. It will,
> I believe, get you going again, Joel.
>
> If you'd like to fix only (and specifically) the rtems target, you might
> think about cabbaging the definition and comments for ASM_OUTPUT_ALIGN
> and stuffing them into i386-rtems.h. I think that'll get you going.
> The comment about recent GAS versions sounds like somehing you should
> note.
>
> This is too sticky for me. I don't know the preferred way to make
> a common file like gas.h know which of the conventions are used. I
> suppose it could be autoconfiscated...
>
>
>
> Index: gas.h
> ===================================================================
> RCS file: /egcs/carton/cvsfiles/egcs/gcc/config/i386/gas.h,v
> retrieving revision 1.3
> diff -u -p -r1.3 gas.h
> --- gas.h 1998/05/21 19:12:18 1.3
> +++ gas.h 1998/07/07 04:38:49
> @@ -80,7 +80,7 @@ Boston, MA 02111-1307, USA. */
> doubt or guess work, and since this file is used for both a.out and other
> file formats, we use one of them. */
>
> -#if 0 /* ??? However, not every port uses binutils 2.6 yet. */
> +#if 1 /* ??? However, not every port uses binutils 2.6 yet. */
> #undef ASM_OUTPUT_ALIGN
> #define ASM_OUTPUT_ALIGN(FILE,LOG) \
> if ((LOG)!=0) fprintf ((FILE), "\t.balign %d\n", 1<<(LOG))
How about this for a proposal?
+ binutils 2.6 is older than anything I have on-line. :)
+ According to gas/Changelog binutils 2.6 was released around Nov 16,
1995.
+ Anyone following the crossgcc instructions for building an i386-coff
toolset should be using a newer binutils since the instructions tell
you to do that.
+ i386-rtems was not even a patch for anything prior to binutils 2.8.
I propose that i386-coff.h be changed to include this version of
ASM_OUTPUT_ALIGN from go32.h:
/* This is how to output an assembler line
that says to advance the location counter
to a multiple of 2**LOG bytes. */
#undef ASM_OUTPUT_ALIGN
#define ASM_OUTPUT_ALIGN(FILE,LOG) \
if ((LOG) != 0) fprintf ((FILE), "\t.p2align %d\n", LOG)
I don't know what to do about gas.h. It is heavily used so I would be
scared to change it. But I think i386-coff can use this and I KNOW this
is OK for i386-rtems. Adding it to i386-coff.h fixes both targets.
It would not take much to convince me that gas.h should not support a
binutils that old. If the target is using that old a version, then the
"good" definition should be overridden in a target specific file. But
that is for someone else to decide on. I am comfortable with the idea of
fixing i386-coff.h for embedded users.
Comments welcomed.
--joel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: i386-rtems(i386-coff) failure in egcs-19980628
1998-07-07 10:14 ` Joel Sherrill
@ 1998-07-09 0:27 ` Jeffrey A Law
0 siblings, 0 replies; 4+ messages in thread
From: Jeffrey A Law @ 1998-07-09 0:27 UTC (permalink / raw)
To: Joel Sherrill; +Cc: Robert Lipe, egcs
In message < Pine.BSF.3.96.980707082620.23755A-100000@vespucci.advicom.net >you write:
> How about this for a proposal?
>
> + binutils 2.6 is older than anything I have on-line. :)
>
> + According to gas/Changelog binutils 2.6 was released around Nov 16,
> 1995.
>
> + Anyone following the crossgcc instructions for building an i386-coff
> toolset should be using a newer binutils since the instructions tell
> you to do that.
>
> + i386-rtems was not even a patch for anything prior to binutils 2.8.
>
> I propose that i386-coff.h be changed to include this version of
> ASM_OUTPUT_ALIGN from go32.h:
Actually, I think we can do this with a relatively simple autoconf
test -- most of the bits we need to check gas versions and features
were added to support the MAX_SKIP_P2ALIGN stuff.
Problem solved once and forever.
In fact, I just hacked up the magic autoconf & gas.h changes, after
some minimal testing I'll check them in. If you could give the failing
x86-rtems port another spin and let me know what happens it would be
greatly appreciated.
jeff
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~1998-07-09 0:27 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-07-06 14:48 i386-rtems(i386-coff) failure in egcs-19980628 Joel Sherrill
1998-07-07 5:29 ` Robert Lipe
1998-07-07 10:14 ` Joel Sherrill
1998-07-09 0:27 ` Jeffrey A Law
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).