Frogging-Family/mostlyportable-gcc

Seg fault during GCC build

flomax opened this issue ยท 13 comments

I have a fresh Arch install up-to-date, and with base-devel, texlive-core, and schedtool all installed, and am getting Segmentation Fault when attempting to build GCC via the .sh script.

https://pastebin.com/hKeTyd1c

Have you changed any setting in the config?
Which CPU do you have?
Any overclock?
Is it reproducible consistently?

Heya, yeah its reproducing the seg fault at the same stage half a dozen times now.

I haven't overclocked anything, Ryzen 1700 system that has previously been building all tkg packages fine until I swapped out old ssd and installed Arch from scratch on a new nvme over the weekend. Temps seem OK.

I'm suspecting building on the nvme drive may be the culprit, but I can/have compiled a 5.6Tkg Kernel without issue ?:-/

I don't think I'm missing any dependencies ? Libsanitiser doesn't need anything special right ?

It seems I'd uncommented the #glibc-2.31 workaround in the .sh file.

Building it with the line commented out no longer seg faults, but does still crash out though.

https://pastebin.com/5aVxvUwJ

Ok. So just compiling current releases/gcc-9 branch (that should be default) with default tooling?
I'd like to try and repro.

Yes that's right, gcc-9. I haven't changed any tools and on a brand new stock Arch install.

Apart from swapping out the old ssd for a new nvme the system hardware is unchanged and was previously building Tkg (and other) packages fine. Any advice would be greatly appreciated :)

Currently installed : https://pastebin.com/DW9i7QHW
mostlyportable-gcc.cfg : https://pastebin.com/buF3H5RF

So, it built successfully on my end.. Maybe your /tmp is too small? What happens if you change _dstdir=/tmp/mostlyportable-gcc in your .cfg to some path you know for sure you have room in?

I have check ulimit is set to unlimitied and;

  • remounted /tmp with 50G and still see seg fault : https://pastebin.com/QZvSU3T6
  • changed the _dstdir to a 800G free folder (on same nvme drive) and call the build script using TEMP=/home/loki/build/tmp ./mostlyportable-gcc.sh - https://pastebin.com/QpER2PCH
  • changed the _distdir to a 100G free folder (on a separate hdd) and call build script using TEMP=/run/media/loki/Storage/tmp ./mostlyportable-gcc.sh: https://pastebin.com/JEWct2Fb

There's no know issues with XFS on nvme that I can find, my mobo BIOS & ucode is up-to-date, it's not a full moon tonight, not sure what else could be the issue.

Just to add to the wtfbbq, I can successfully build mingw-mostlyportable-9.3.1-releases-gcc.9.3.0.r62.g79166bd28d0.
๐Ÿคท

Can't find anything so far. Pretty annoying not being able to repro the issue on my end. I have asked a friend with a Ryzen CPU (zen2 though) and no issue either.

It's all good. I appreciate the help so far.. I shall keep digging on my end and hopefully figure it out :)

I'll come back to you if I find a clue or got an idea. Maybe someone else will have stumbled upon the issue before and will be able to help.

So I haven't added anything to my system except for mono, ccache and mediainfo - gave it another shot this afternoon and can report success for gcc-mostlyportable-9.3.1-releases-gcc.9.3.0.r78.g0c509c6b5ac

I don't know how or why I was getting the earlier segfault still, but all now seems to be friggin froggalicious and working as expected. <3

What the frog ๐Ÿธ
Maybe some backport fixed that weird case for you? https://github.com/gcc-mirror/gcc/commits/releases/gcc-9

Well, all in all great news! Enjoy :)