Skip to contentSkip to conversation

New: nodejs crashes when built with gcc 4.9

Buildroot bugzilla at busybox.net 1 participant 11 messages Apr 30, 2015 – Dec 3, 2015

lore
Share & tools
lore
#0 lore raw

https://bugs.busybox.net/show_bug.cgi?id=8066

Host: Xeon
Target: x86_64 i7
Summary: nodejs crashes when built with gcc 4.9
Product: buildroot
Version: 2015.02
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P5
Component: Other
AssignedTo: unassigned at buildroot.uclibc.org
ReportedBy: ian_ormshaw at waters.com
CC: buildroot at uclibc.org
Estimated Hours: 0.0

Created attachment 6016
--> https://bugs.busybox.net/attachment.cgi?id=6016
Config file

nodejs crashed whenever it is run on an i7 system when compiled with gcc 4.9. Using the exact same configuration but with gcc 4.8 works correctly.

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#1 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #1 from Thomas Petazzoni <[email protected]> 2015-06-03 15:19:54 UTC --- To help us in solving this bug, could you provide a minimal working Buildroot configuration, and a minimal non-working Buildroot configuration, as well as
the exact steps to reproduce the problem?

Also, please be sure to include the exact Buildroot version you have used, so that we can now which version of gcc 4.8.x and gcc 4.9.x you have tested.

Thanks!

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#2 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #2 from Dr I J Ormshaw <[email protected]> 2015-06-10 08:53:56 UTC --- Created attachment 6066
--> https://bugs.busybox.net/attachment.cgi?id=6066
The good config file

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#3 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #3 from Dr I J Ormshaw <[email protected]> 2015-06-10 08:54:42 UTC --- Created attachment 6071
--> https://bugs.busybox.net/attachment.cgi?id=6071
The bad config file

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#4 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #4 from Dr I J Ormshaw <[email protected]> 2015-06-10 08:55:29 UTC --- Created attachment 6076
--> https://bugs.busybox.net/attachment.cgi?id=6076
The differences between the good and bad config

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#5 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #5 from Dr I J Ormshaw <[email protected]> 2015-06-10 09:00:34 UTC --- I've re-created the issue and attached the good and bad config files, I've also attaches the differences between the two, as a patch.

The version of buildroot I am using is

2015.02
6bf057b0f2ba188397a691f74877a4a30aaea3f9

The console output for the failure is:

[root at buildroot ~]# node
traps: node[194] general protection ip:736725 sp:7ffc3c721350 error:0 in node[400000+73c000]
Segmentation fault

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#6 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

Jeroen Roovers <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |jer at xs4all.nl

--- Comment #6 from Jeroen Roovers <[email protected]> 2015-09-30 12:55:04 UTC --- On an ARM system (cortex-a7) I am seeing a similar problem when I build everything with gcc-4.9.*. It doesn't crash, though, it merely exits certain functions early, causing it to output invalid HTTP headers. I have seen some references on the wider Internet pointing to similar problems, but those were not connected to a specific GCC version or even the same OS. The only thing I am certain of is that GCC 4.9 miscompiles nodejs, including version 4.1.1. I haven't tried with libuv and libhttpparser properly in place, though.

Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
#7 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

Mike Frysinger <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

               Host|Xeon                        |Xeon x86_64 i7
             Target|x86_64 i7                   |
Signature · 5 lines
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20151202/80af0736/attachment.html>
#8 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

Martin <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at buildroot.uclibc |martin at barkynet.com
|.org |

--- Comment #7 from Martin <[email protected]> --- (In reply to Dr I J Ormshaw from comment #5)

Quoted 8 lines

I've re-created the issue and attached the good and bad config files, I've also attaches the differences between the two, as a patch.

The version of buildroot I am using is

2015.02
6bf057b0f2ba188397a691f74877a4a30aaea3f9

Quoted 7 lines

The console output for the failure is:

[root at buildroot ~]# node
traps: node[194] general protection ip:736725 sp:7ffc3c721350 error:0 in node[400000+73c000]
Segmentation fault

I've not managed to reproduce your issue. Your config files contains various customisations like an override file, kernel patches, overlay etc so I'm not able to full replicate your setup.

Instead I used buildroot version 2015.11 and the qemu_x86_64_defconfig as a start point. I configured for a core i7, gcc 4.9.3, glibc and node.js v0.10.40 and node works fine in qemu. I even tried eglibc as you do (which is now deprecated) and it worked fine too.

I can only suggest you try to upgrade to buildroot 2015.11 and test again, perhaps your issue has been fixed. If you still find the issue then can you please attach a minimal non-working Buildroot configuration, removing any custom override files and packages which are not needed to reproduce the issue.

Thanks

Martin

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#9 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

--- Comment #8 from Martin <[email protected]> --- (In reply to Jeroen Roovers from comment #6)

Quoted 8 lines

On an ARM system (cortex-a7) I am seeing a similar problem when I build everything with gcc-4.9.*. It doesn't crash, though, it merely exits certain functions early, causing it to output invalid HTTP headers. I have seen some references on the wider Internet pointing to similar problems, but those were not connected to a specific GCC version or even the same OS. The only thing I am certain of is that GCC 4.9 miscompiles nodejs, including version 4.1.1. I haven't tried with libuv and libhttpparser properly in place, though.

I think this might be a different issue, the original issue is about a crash.

If you think you still have an issue can you please raise a new bug. In the bug please attach a minimal non-working Buildroot configuration so we can try to reproduce it.

Thanks

Martin

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#10 lore raw

[Buildroot] [Bug 8066] nodejs crashes when built with gcc 4.9

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=8066

Thomas Petazzoni <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

             Status|NEW                         |RESOLVED
         Resolution|---                         |WORKSFORME

--- Comment #9 from Thomas Petazzoni <[email protected]> --- Thanks a lot Martin for taking the time to look at this bug, and to attempt to reproduce it!

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.