Bug 70098
Summary: | Compiler bails out when compiling mozilla with pentium4 cpu optimisation | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | Chris Chabot <chabotc> | ||||||||||||||
Component: | gcc | Assignee: | Jakub Jelinek <jakub> | ||||||||||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | |||||||||||||||
Severity: | medium | Docs Contact: | |||||||||||||||
Priority: | medium | ||||||||||||||||
Version: | 8.0 | ||||||||||||||||
Target Milestone: | --- | ||||||||||||||||
Target Release: | --- | ||||||||||||||||
Hardware: | i386 | ||||||||||||||||
OS: | Linux | ||||||||||||||||
Whiteboard: | |||||||||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||||||||
Doc Text: | Story Points: | --- | |||||||||||||||
Clone Of: | Environment: | ||||||||||||||||
Last Closed: | 2003-06-20 03:19:23 UTC | Type: | --- | ||||||||||||||
Regression: | --- | Mount Type: | --- | ||||||||||||||
Documentation: | --- | CRM: | |||||||||||||||
Verified Versions: | Category: | --- | |||||||||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||||||||
Embargoed: | |||||||||||||||||
Attachments: |
|
Description
Chris Chabot
2002-07-30 11:08:05 UTC
Please provide preprocessed source for this (jsdtoa.i). How do i get this .i file? Even if i compile the .c file by hand, it doesnt create any .i files.. the line i use to compile it is: gcc -o jsdtoa.o -c -DOSTYPE=\"Linux2.4.18-7\" -DOSARCH=\"Linux\" -DOJI -DEXPORT_JS_API -DJS_USE_SAFE_ARENA -I../../dist/include/js -I../../dist/include -I/usr/src/redhat/BUILD/mozilla/dist/include/nspr -I. -I/usr/X11R6/include -fPIC -I/usr/X11R6/include -Wall -W -Wno-unused -Wpointer-arith -Wcast-align -pedantic -Wno-long-long -O2 -march=pentium4 -mcpu=pentium4 -pthread -DNDEBUG -DTRIMMED -O2 -march=pentium4 -mcpu=pentium4 -I/usr/X11R6/include -include ../../config-defs.h -DMOZILLA_CLIENT -Wp,-MD,.deps/jsdtoa.pp jsdtoa.c This results in the error i originaly described, but find -name "*.i" tells me there's no .i files to be found anywhere in the build tree.. Is there anything i can add/remove from the compile command so it does generate this .i file? Yes. Either add -save-temps option to the command line, or replace "-o jsdtoa.o -c" with "-o jsdtoa.i -E". Ps, adding the jsdtoa.i file is failing due to a oracle/bugzilla error. I have send the file as attachment in a direct email. (All the attachments listed in this bug are empty since the storare failed). I will try to re-add it again in an hour or so Simplified into: /* { dg-do compile } */ /* { dg-options "-O2" } */ /* { dg-options "-O2 -march=pentium4" } */ const double h [10]; typedef union { double u1; struct { unsigned int u21, u22; } u2; } U; double bar (double x); double foo (int x, unsigned int y, unsigned int z) { int a, b; double c; b = x < 15 + 1 ? x : 15 + 1; c = y; if (b > 9) c = h [b - 9] * c + z; a = 0; if (((__extension__ ({ U d; d.u1 = (c); d.u2.u21; })) & 1)) c += bar (c); return c; } Works for me with the 3.2-7 compiler It still fails for me. I tried upgrading to the 3.2.1 compiler (rawhide), and still a similar error: gcc -o jsdtoa.o -c -DOSTYPE="Linux2.4" -DOSARCH="Linux" -DOJI -DEXPORT_JS_API -DJS_USE_SAFE_ARENA -I../../dist/include/js -I../../dist/include -I/usr/src/redhat/BUILD/mozilla/dist/include/nspr -I. -I/usr/X11R6/include -fPIC -I/usr/X11R6/include -Wall -W -Wno-unused -Wpointer-arith -Wcast-align -pedantic -Wno-long-long -O2 -march=pentium4 -mcpu=pentium4 -pthread -pipe -DNDEBUG -DTRIMMED -ffunction-sections -O2 -march=pentium4 -mcpu=pentium4 -I/usr/X11R6/include -include ../../mozilla-config.h -DMOZILLA_CLIENT -Wp,-MD,.deps/jsdtoa.pp jsdtoa.c jsdtoa.c: In function `ulp': jsdtoa.c:987: warning: `a' might be used uninitialized in this function jsdtoa.c: In function `b2d': jsdtoa.c:1018: warning: `d' might be used uninitialized in this function jsdtoa.c: In function `JS_strtod': jsdtoa.c:1239: warning: `rv0' might be used uninitialized in this function jsdtoa.c:1874: unable to find a register to spill in class `AREG' jsdtoa.c:1874: this is the insn: (insn:QI 1952 1951 1953 (set (reg:CCNO 17 flags) (compare:CCNO (and:SI (subreg:SI (reg/v:DI 21 rxmm0 [268]) 0) (const_int 1 [0x1])) (const_int 0 [0x0]))) 281 {testsi_1} (insn_list 1948 (nil)) (expr_list:REG_DEAD (reg/v:DI 21 rxmm0 [268]) (nil))) jsdtoa.c:1874: confused by earlier errors, bailing out This is while compiling mozilla-1.2.1 btw. I'll attach the generated jsdtoa.i file to the bug Created attachment 88750 [details]
Gcc 3.2.1 / Moz 1.2.1 generated jsdtoa.i file
Now works with recent gcc 3.2 (in rh9 and rawhide) and 3.3 (rawhide) packages, so closing bug. (Confirmed with both compiler versions using -march=pentium4 -pipe flags and mozilla-1.4rc2) Thanks for your time and great work |