Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 311863 - "internal compiler error: Segmentation fault" during "genkernel all" command
Summary: "internal compiler error: Segmentation fault" during "genkernel all" command
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-29 00:54 UTC by gentoo
Modified: 2010-04-07 08:55 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gentoo 2010-03-29 00:54:53 UTC
A segmentation fault reported by genkernel.

From genkernel.log after running "genkernel all":

[snip]

drivers/gpu/drm/i915/i915_suspend.c: In function 'i915_save_state':
drivers/gpu/drm/i915/i915_suspend.c:611: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugs.gentoo.org/> for instructions.
make[4]: *** [drivers/gpu/drm/i915/i915_suspend.o] Error 1
make[3]: *** [drivers/gpu/drm/i915] Error 2
make[2]: *** [drivers/gpu/drm] Error 2
make[1]: *** [drivers/gpu] Error 2
make: *** [drivers] Error 2
make: *** Waiting for unfinished jobs....

[snip]

* Gentoo Linux Genkernel; Version 3.4.10.906
* Running with options: all

* ERROR: Failed to compile the "modules" target...
* -- Grepping log... --
* -- End log... --
* Please consult /var/log/genkernel.log for more information and any
* errors that were reported above.


Reproducible: Always

Steps to Reproduce:
1. Run "genkernel all"
2.
3.

Actual Results:  
A segmentation fault was logged.

Expected Results:  
Completed building the modules without segfaulting.


The first time this happened, it reported the segfault in drivers/infiniband/hw/mthca/mthca_qp.c (reported as the last line of the file).

I commented out that module in /usr/share/genkernel/arch/x86_64/kernel-config and re-ran genkernel. The segfault then happened in drivers/gpu/drm/i915/i915_suspend.c
Comment 1 Alex Legler (RETIRED) archtester gentoo-dev Security 2010-03-29 06:22:47 UTC
Attach emerge --info.
Comment 2 gentoo 2010-03-29 07:02:06 UTC
Portage 2.1.7.17 (default/linux/amd64/10.0, gcc-4.3.4, glibc-2.10.1-r1, 2.6.31-gentoo-r6 x86_64)
=================================================================
System uname: Linux-2.6.31-gentoo-r6-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_6400+-with-gentoo-1.12.13
Timestamp of tree: Mon, 29 Mar 2010 04:00:01 +0000
app-shells/bash:     4.0_p35
dev-java/java-config: 2.1.10
dev-lang/python:     2.6.4-r1
dev-util/cmake:      2.6.4-r3
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.13, 2.63-r1
sys-devel/automake:  1.8.5-r3, 1.9.6-r2, 1.10.3
sys-devel/binutils:  2.18-r3
sys-devel/gcc:       4.3.4
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
virtual/os-headers:  2.6.30-r1
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=native -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=native -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/"
LDFLAGS="-Wl,-O1"
LINGUAS="en_GB"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X acl alsa amd64 berkdb bzip2 cli cracklib crypt cups cxx dbus dri exif fortran gdbm gif gnome gpm gtk hal iconv imagemagick imlib ipv6 java jbig jpeg jpeg2k kde mmx mng modules mudflap multilib mysql ncurses nls nptl nptlonly opengl openmp pam pcre perl png pppd python raw readline reflection session spl sse sse2 ssl svg symlink sysfs tcpd threads tiff unicode wmf xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CAMERAS="adc65 agfa_cl20 aox barbie canon casio_qv clicksmart310 digigr8 digita dimagev dimera3500 directory enigma13 fuji gsmart300 hp215 iclick jamcam jd11 jl2005a kodak_dc120 kodak_dc210 kodak_dc240 kodak_dc3200 kodak_ez200 konica konica_qm150 largan lg_gsm mars mustek panasonic_coolshot panasonic_dc1000 panasonic_dc1580 panasonic_l859 pccam300 pccam600 polaroid_pdc320 polaroid_pdc640 polaroid_pdc700 ptp2 ricoh ricoh_g3 samsung sierra sipix_blink sipix_blink2 sipix_web2 smal sonix sony_dscf1 sony_dscf55 soundvision spca50x sq905 stv0674 stv0680 sx330z template topfield toshiba_pdrm11" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nvidia" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY

Comment 3 Chí-Thanh Christopher Nguyễn gentoo-dev 2010-03-30 11:07:55 UTC
Internal compiler error usually points to either a broken toolchain (if the segfault always happens in the same file) or hardware problems such as overheating (if the segfaults happens in random places).
Comment 4 gentoo 2010-03-30 16:33:26 UTC
> Internal compiler error usually points to either a broken toolchain (if the
> segfault always happens in the same file)

It doesn't. Changing the kernel config changes the file in which it occurs.

> or hardware problems such as overheating (if the segfaults happens in random places).

They don't. With the same kernel config, the segfault always happens in the same place.
Comment 5 gentoo 2010-04-05 19:08:54 UTC
After chaning the kernel .config, the segfault now being reported in megaraid_mbox.c:

  CC [M]  drivers/usb/serial/ezusb.o
  CC [M]  drivers/scsi/megaraid/megaraid_mbox.o
  CC [M]  drivers/usb/serial/aircable.o
  CC [M]  drivers/usb/serial/ark3116.o
drivers/scsi/megaraid/megaraid_mbox.c: In function 'megaraid_probe_one':
drivers/scsi/megaraid/megaraid_mbox.c:433: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugs.gentoo.org/> for instructions.
make[3]: *** [drivers/scsi/megaraid/megaraid_mbox.o] Error 1
make[2]: *** [drivers/scsi/megaraid] Error 2
make[1]: *** [drivers/scsi] Error 2
make[1]: *** Waiting for unfinished jobs....
  CC [M]  drivers/usb/storage/alauda.o
  CC [M]  drivers/usb/serial/ch341.o
Comment 6 Chí-Thanh Christopher Nguyễn gentoo-dev 2010-04-07 03:07:23 UTC
(In reply to comment #4)
> > Internal compiler error usually points to either a broken toolchain (if the
> > segfault always happens in the same file)
> 
> It doesn't. Changing the kernel config changes the file in which it occurs.

Of course if you change the kernel config, then you will be compiling something different so the error happens in another place. So your toolchain is broken.
Comment 7 Panagiotis Christopoulos (RETIRED) gentoo-dev 2010-04-07 08:55:11 UTC
So you say that this happens only when you try to compile a kernel? What if you try to emerge something else, eg. try to reemerge glibc (emerge glibc). Probably, your toolchain is broken, which means that maybe you'll have to reemerge your gcc, glibc,binutils etc... Reopen the bug only if you are certain that this is not a toolchain/hardware issue. Thank you for your report. I resolve the bug as TEST-REQUEST for the time being.