Skip to contentSkip to conversation

Numerous ARC related toolchain issues

Buildroot Thomas Petazzoni 2 participants 4 messages Jun 9, 2016 – Jun 10, 2016

lore
Share & tools
lore
#0 lore raw

Hello Alexey,

It seems like since the latest update of the ARC tools, we're seeing quite a few build failures caused by the toolchain:

http://autobuild.buildroot.net/results/d73/d732127d136bacc6bc17b742028691437df7f5f9/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566

http://autobuild.buildroot.net/results/cb8/cb8bd3a01c7a6fadb20f18c1a3cbfabc52f3a6ff/build-end.log
/tmp/ccKi33Rl.s: Assembler messages:
/tmp/ccKi33Rl.s:578: Error: @dtpoff is not a complex relocation. /tmp/ccKi33Rl.s:578: Error: extra comma /tmp/ccKi33Rl.s:578: Error: syntax error /tmp/ccKi33Rl.s:588: Error: @dtpoff is not a complex relocation. /tmp/ccKi33Rl.s:588: Error: extra comma /tmp/ccKi33Rl.s:588: Error: syntax error

http://autobuild.buildroot.net/results/37a/37a57f29c6632fcdb18670a18328679dee925240/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566

http://autobuild.buildroot.net/results/1c1/1c14a7cbda1dce8867275ba2f2c70054fdbfbbbc/build-end.log
(same, but on wireshark)

These are all with the internal toolchain backend, so we're building with the latest ARC toolchain components.

Are these problems already known? They seem to be new, I don't think they were appearing with the previous release of ARC tools.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#1 lore raw

Hi Thomas,

Thanks for taking care and spending your time on this analysis. We did see all these failures and already working hard to fix them.

Below some more details on particular failures.

Quoted 7 lines · Thomas Petazzoni

Hello Alexey,

It seems like since the latest update of the ARC tools, we're seeing quite a few build failures caused by the toolchain:

http://autobuild.buildroot.net/results/d73/d732127d136bacc6bc17b742028691437df7f5f9/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566

This is yet another manifestation of PIE invocation on ARC. We'll need to disable usage of PIE in linuxpam.

Quoted 8 lines

http://autobuild.buildroot.net/results/cb8/cb8bd3a01c7a6fadb20f18c1a3cbfabc52f3a6ff/build-end.log
/tmp/ccKi33Rl.s: Assembler messages:
/tmp/ccKi33Rl.s:578: Error: @dtpoff is not a complex relocation. /tmp/ccKi33Rl.s:578: Error: extra comma /tmp/ccKi33Rl.s:578: Error: syntax error /tmp/ccKi33Rl.s:588: Error: @dtpoff is not a complex relocation. /tmp/ccKi33Rl.s:588: Error: extra comma /tmp/ccKi33Rl.s:588: Error: syntax error

That one was reported to our toolchain guys and we're looking forward to hearing back from them.

Quoted 2 lines

http://autobuild.buildroot.net/results/37a/37a57f29c6632fcdb18670a18328679dee925240/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566

Given the same assertion that was triggered and that line in the log:
----------------------->8--------------------
checking whether /home/buildroot/build/instance-1/output/host/usr/bin/arc-buildroot-linux-uclibc-gcc accepts -fPIE... yes
----------------------->8--------------------
I would assume PIE is guilty here, so we will disable PIE in bluez-utils.

Quoted 2 lines

http://autobuild.buildroot.net/results/1c1/1c14a7cbda1dce8867275ba2f2c70054fdbfbbbc/build-end.log
(same, but on wireshark)

Looks like the same is applicable to wireshark.

Quoted 5 lines

These are all with the internal toolchain backend, so we're building with the latest ARC toolchain components.

Are these problems already known? They seem to be new, I don't think they were appearing with the previous release of ARC tools.

As said above we know about all of these and trying to resolve them ASAP. Be prepared for patches with fixes next week :)

Again thanks for all your efforts in making BR a better product!

-Alexey

#2 lore raw

Hello,

Quoted 5 lines · Alexey Brodkin
Quoted 2 lines

http://autobuild.buildroot.net/results/d73/d732127d136bacc6bc17b742028691437df7f5f9/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566

This is yet another manifestation of PIE invocation on ARC. We'll need to disable usage of PIE in linuxpam.

Ah, OK. Shouldn't gcc be modified on ARC to either ignore the pie flag, or alternatively bail out immediately with a clear error? At least it would be much more easy to analyze the error than a weird assertion failure down the road in the linker.

Quoted 2 lines

That one was reported to our toolchain guys and we're looking forward to hearing back from them.

ACK!

Quoted 2 lines

As said above we know about all of these and trying to resolve them ASAP. Be prepared for patches with fixes next week :)

Awesome, thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#3 lore raw

Hi Thomas,

Quoted 8 lines · Thomas Petazzoni

Hello,

Quoted 4 lines · Alexey Brodkin
Quoted 4 lines

http://autobuild.buildroot.net/results/d73/d732127d136bacc6bc17b742028691437df7f5f9/build-end.log
BFD (GNU Binutils) 2.26.51.20160308 assertion fail elf32-arc.c:1566??

Quoted 7 lines
Quoted 2 lines

This is yet another manifestation of PIE invocation on ARC. We'll need to disable usage of PIE in linuxpam.

Ah, OK. Shouldn't gcc be modified on ARC to either ignore the pie flag, or alternatively bail out immediately with a clear error? At least it would be much more easy to analyze the error than a weird assertion failure down the road in the linker.

See PIE is a real requirement for U-Boot (because it relocates itself on early boot) and for some reason U-Boot gets built with -PIE flag perfectly fine.

So we cannot just disable PIE support at least until U-Boot for ARC gets auto-relocated. But for user-space apps indeed we don't support PIE still and so existing code in toolchain fails here and there.

Funny enough that's better to see a failure during compilation compared to silent segfault on attempt to run already built app. BTW now I can recall that exactly this hit me with older toolchain - I needed wireshark so I built it flawlessly but on execution dumpcap was segfaulting right on start. But being lazy enough I never sent a patch to disable PIE in Wireshark :(

-Alexey