This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/48356] New: Compiler error on compilation of linux source file p80211wep.c if -O2 is used


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48356

           Summary: Compiler error on compilation of linux source file
                    p80211wep.c if -O2 is used
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Severity: major
          Priority: P3
         Component: c
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: molitor@microbiology-bonn.de


Trying to compile the current Linux kernel (Linux 2.6.39-rc1, latest commit:
0ce790e7d736cedc563e1fb4e998babf5a4dbc3d), I ran across a compiler error.

The source file linux-2.6/drivers/staging/wlan-ng/p80211wep.c causes this error
message:

gcc -Wp,-MD,drivers/staging/wlan-ng/.p80211wep.o.d  -nostdinc -isystem
/usr/lib/gcc/i686-pc-linux-gnu/4.6.0/include -I/linux-2.6/arch/x86/include
-Iinclude  -include include/generated/autoconf.h -D__KERNEL__ -Wall -Wundef
-Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common
-Werror-implicit-function-declaration -Wno-format-security
-fno-delete-null-pointer-checks -O2 -m32 -msoft-float -mregparm=3
-freg-struct-return -mpreferred-stack-boundary=2 -march=i686 -mtune=core2
-mtune=generic -maccumulate-outgoing-args -Wa,-mtune=generic32 -ffreestanding
-fstack-protector -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1
-DCONFIG_AS_CFI_SECTIONS=1 -pipe -Wno-sign-compare
-fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow
-Wframe-larger-than=1024 -fno-omit-frame-pointer -fno-optimize-sibling-calls -g
-Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow
-fconserve-stack -DCC_HAVE_ASM_GOTO -save-temps  -DMODULE  -D"KBUILD_STR(s)=#s"
-D"KBUILD_BASENAME=KBUILD_STR(p80211wep)" 
-D"KBUILD_MODNAME=KBUILD_STR(prism2_usb)" -c -o
drivers/staging/wlan-ng/.tmp_p80211wep.o drivers/staging/wlan-ng/p80211wep.c
gcc: warning: -pipe ignored because -save-temps specified
drivers/staging/wlan-ng/p80211wep.c: In function 'wep_decrypt':
drivers/staging/wlan-ng/p80211wep.c:229:1: internal compiler error: in
form_sum, at reload.c:5338
Please submit a full bug report,
with preprocessed source if appropriate.

The included file p80211wep.i causes this error if compiled with 

gcc  -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs
-fno-strict-aliasing -fno-common -Werror-implicit-function-declaration
-Wno-format-security -fno-delete-null-pointer-checks -O2 -m32 -msoft-float
-mregparm=3 -freg-struct-return -mpreferred-stack-boundary=2 -march=i686
-mtune=core2 -mtune=generic -maccumulate-outgoing-args -Wa,-mtune=generic32
-ffreestanding -fstack-protector -DCONFIG_AS_CFI=1
-DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -pipe
-Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2
-mno-3dnow -Wframe-larger-than=1024 -fno-omit-frame-pointer
-fno-optimize-sibling-calls -g -Wdeclaration-after-statement -Wno-pointer-sign
-fno-strict-overflow -fconserve-stack -DCC_HAVE_ASM_GOTO -save-temps  -DMODULE 
-D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(p80211wep)" 
-D"KBUILD_MODNAME=KBUILD_STR(prism2_usb)" -c  p80211wep.i 

With -O instead of -O2, the file compiles nicely.

Best regards,

Ernst

P.S.: Warmest thanks for the most impressive gcc tool chain.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]