Skip to contentSkip to conversation

ppc -Os and _restgpr_##_x errors

U-Boot Mike Frysinger 5 participants 9 messages Nov 10, 2011 – Nov 14, 2011

lore
Share & tools
lore
#0 lore raw

am i the only one seeing errors like:
board/esd/cpciiser4/libcpciiser4.o: In function `board_early_init_f':
board/esd/cpciiser4/cpciiser4.c:139: undefined reference to `_restgpr_26_x'

i'm using a gcc-4.5.x toolchain here. should we import crtsavres.S from Linux to fix this ?
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20111109/60dfe963/attachment.pgp

#1 lore raw

Dear Mike Frysinger,

Quoted 7 lines · In message <[email protected]> you wrote:

am i the only one seeing errors like:
board/esd/cpciiser4/libcpciiser4.o: In function `board_early_init_f':
board/esd/cpciiser4/cpciiser4.c:139: undefined reference to `_restgpr_26_x'

i'm using a gcc-4.5.x toolchain here. should we import crtsavres.S from Linux to fix this ?

No, we should not. You should switch to a compiler version where this problem has been fixed. See second entry at
http://www.denx.de/wiki/U-Boot/GccBugsAndIssues

Best regards,

Wolfgang Denk

Signature · 4 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
He is truly wise who gains wisdom from another's mishap.
#2 lore raw
Quoted 6 lines · On Thursday 10 November 2011 00:32:45 Wolfgang Denk wrote:
Quoted 5 lines · Mike Frysinger

am i the only one seeing errors like:
board/esd/cpciiser4/libcpciiser4.o: In function `board_early_init_f':
board/esd/cpciiser4/cpciiser4.c:139: undefined reference to `_restgpr_26_x'

Quoted 6 lines
Quoted 2 lines

i'm using a gcc-4.5.x toolchain here. should we import crtsavres.S from Linux to fix this ?

No, we should not. You should switch to a compiler version where this problem has been fixed. See second entry at
http://www.denx.de/wiki/U-Boot/GccBugsAndIssues

thanks ... upgrading to gcc-4.6.2 from gcc-4.5.3 fixed things. when i read the gcc thread, it sounded like it wasn't optional behavior, but i guess they changed that with gcc-4.6.x.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20111110/e27a0ac6/attachment.pgp

#3 lore raw
In reply to Mike Frysinger
Quoted 6 lines · Mike Frysinger

am i the only one seeing errors like:
board/esd/cpciiser4/libcpciiser4.o: In function `board_early_init_f':
board/esd/cpciiser4/cpciiser4.c:139: undefined reference to `_restgpr_26_x'

i'm using a gcc-4.5.x toolchain here. ?should we import crtsavres.S from Linux to fix this ?

Some projects fix this manually. For example kexec adds this:

https://github.com/horms/kexec-tools/blob/master/purgatory/arch/ppc/misc.S

Not that this is a good approach....

-M

#4 lore raw
Quoted 5 lines · On 11/10/2011 01:47 PM, McClintock Matthew-B29882 wrote:
Quoted 4 lines · Mike Frysinger

am i the only one seeing errors like:
board/esd/cpciiser4/libcpciiser4.o: In function `board_early_init_f':
board/esd/cpciiser4/cpciiser4.c:139: undefined reference to `_restgpr_26_x'

Quoted 8 lines
Quoted 2 lines

i'm using a gcc-4.5.x toolchain here. should we import crtsavres.S from Linux to fix this ?

Some projects fix this manually. For example kexec adds this:

https://github.com/horms/kexec-tools/blob/master/purgatory/arch/ppc/misc.S

Not that this is a good approach....

Shouldn't libgcc provide this?

-Scott

#5 lore raw
Quoted 1 line · Scott Wood

Shouldn't libgcc provide this?

It's not being provided by certain toolchains...

-M

#6 lore raw
Quoted 6 lines · Scott Wood
Quoted 1 line

Shouldn't libgcc provide this?

It's not being provided by certain toolchains...

-M

Well there is a reason why one should stick to ELDK ;-)

Quoted 4 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

#7 lore raw
Quoted 1 line · Marek Vasut

Well there is a reason why one should stick to ELDK ;-)

It depends on what version of GCC you want to use as well.

-M

#8 lore raw
In reply to Scott Wood

Dear Scott Wood,

Quoted 3 lines · In message <[email protected]> you wrote:
Quoted 3 lines
Quoted 3 lines

i'm using a gcc-4.5.x toolchain here. should we import crtsavres.S from Linux to fix this ?

...

Quoted 3 lines
Quoted 1 line

Not that this is a good approach....

Shouldn't libgcc provide this?

If GCC generates such instruction sequences, it definitely should provide support for these in libgcc. Even better if it doesn't generate such code at all.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
A woman should have compassion.
	-- Kirk, "Catspaw", stardate 3018.2