[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #7 from burnus at gcc dot gnu dot org 2007-03-11 21:42 --- > Can you see if the patch I committed this morning fixes this problem? http://gcc.gnu.org/ml/gcc-patches/2007-03/msg00664.html Yes, the patch fixes this problem. Thanks! -- burnus at gcc dot gnu dot org changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #6 from ian at airs dot com 2007-03-11 20:46 --- Can you see if the patch I committed this morning fixes this problem? 2007-03-11 Ian Lance Taylor <[EMAIL PROTECTED]> * tree-vrp.c (vrp_int_const_binop): Handle PLUS_EXPR and the *_DIV_EXPR codes correctly with overflow infinities. Thanks. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #5 from burnus at gcc dot gnu dot org 2007-03-11 14:07 --- Ian, looking at the changelog, it seems as if your commit http://gcc.gnu.org/viewcvs?view=rev&revision=122487 r122487 | ian | 2007-03-02 21:09:31 +0100 (Fri, 02 Mar 2007) | 35 lines Used signed infinities in VRP. could be the cause of this problem. -- burnus at gcc dot gnu dot org changed: What|Removed |Added CC||ian at gcc dot gnu dot org Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|-00-00 00:00:00 |2007-03-11 14:07:33 date|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #4 from dominiq at lps dot ens dot fr 2007-03-11 13:16 --- Note that the bug affect lapack/blas/{s,d}scal.f. Note also that in the *optimized* dumps of lapack/blas/{c,z}scal.f there are several: Invalid sum of incoming frequencies , should be cscal.f: ... Invalid sum of incoming frequencies 2224, should be 2116 :; D.1073 = () ivtmp.47; CR.63 = MEM[index: D.1073]; CI.64 = MEM[index: D.1073, offset: 4]; MEM[index: D.1073] = CR.61 * CR.63 - CI.62 * CI.64; MEM[index: D.1073, offset: 4] = CR.61 * CI.64 + CI.62 * CR.63; ivtmp.44 = ivtmp.44 + 1; ivtmp.47 = ivtmp.47 + 8; if ((int4) ivtmp.44 == D.968) goto ; else goto ; Invalid sum of incoming frequencies 2322, should be 2430 :; return; and zscal.f: ... Invalid sum of incoming frequencies 10511, should be 1 :; D.1095 = () ivtmp.59; CR.21 = MEM[index: D.1095]; CI.22 = MEM[index: D.1095, offset: 8]; MEM[index: D.1095] = CR.64 * CR.21 - CI.65 * CI.22; MEM[index: D.1095, offset: 8] = CR.64 * CI.22 + CI.65 * CR.21; ivtmp.53 = ivtmp.53 + 1; ivtmp.59 = ivtmp.59 + ivtmp.62; if ((int4) ivtmp.53 == D.967) goto ; else goto ; :; CR.19 = REALPART_EXPR <*za>; CI.20 = IMAGPART_EXPR <*za>; ivtmp.50 = () &REALPART_EXPR <(*zx)[0]>; ivtmp.47 = 0; Invalid sum of incoming frequencies 4723, should be 4493 :; D.1079 = () ivtmp.50; CR.25 = MEM[index: D.1079]; CI.26 = MEM[index: D.1079, offset: 8]; MEM[index: D.1079] = CR.19 * CR.25 - CI.20 * CI.26; MEM[index: D.1079, offset: 8] = CR.19 * CI.26 + CI.20 * CR.25; ivtmp.47 = ivtmp.47 + 1; ivtmp.50 = ivtmp.50 + 16; if ((int4) ivtmp.47 == D.967) goto ; else goto ; Invalid sum of incoming frequencies 4420, should be 5160 :; return; -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #3 from dominiq at lps dot ens dot fr 2007-03-11 12:58 --- The following reduced test case PROGRAM LINPK PARAMETER (N=2500,LDA=N+1) DOUBLE PRECISION a(LDA,N) , b(N) , x(N) a = 1.0 print *, 'before DSCAL' CALL DSCAL(N-1,1.0D0,A(2,1),1) print *, 'after DSCAL' END SUBROUTINE DSCAL(N,Da,Dx,Incx) DOUBLE PRECISION Da , Dx(*) INTEGER i , Incx , m , mp1 , N , nincx ! print *, N, Da, Dx(MOD(N,5)+1), Incx IF ( N.GT.0 ) THEN mp1 = MOD(N,5) + 1 DO i = mp1 , N , 5 Dx(i) = Da*Dx(i) ENDDO ENDIF END shows the bug: [karma] lin/source% gfc -O2 linpk_red.f90 [karma] lin/source% a.out before DSCAL Bus error Looking at linpk_red.f90.116t.optimized, the loop in DSCAL reads :; D.1053 = () ivtmp.54; MEM[index: D.1053] = pretmp.36 * MEM[index: D.1053]; ivtmp.45 = ivtmp.45 + 1; ivtmp.54 = ivtmp.54 + 40; if (ivtmp.45 == 2147483647) goto L.4; else goto ; I don't know the origin of 2147483647, but it looks pretty bad!-(even for me) Note that DSCAL appears in linpk.f90, rnflow.f90, and test_fpu.f90. PS this is my second attempt to post this, I apologize if the first one shows up later. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #2 from dominiq at lps dot ens dot fr 2007-03-10 10:49 --- Confirmed on OSX 10.3.9 with snapshot 4.3.0 20070309. -- dominiq at lps dot ens dot fr changed: What|Removed |Added CC||dominiq at lps dot ens dot ||fr http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
-- pinskia at gcc dot gnu dot org changed: What|Removed |Added Target Milestone|--- |4.3.0 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030
[Bug middle-end/31030] [4.3 Regression] Segmentation fault with -O2
--- Comment #1 from burnus at gcc dot gnu dot org 2007-03-09 22:49 --- For completeness: This is on x86_64-unknown-linux-gnu -- burnus at gcc dot gnu dot org changed: What|Removed |Added Severity|normal |critical Summary|[Regression 4.3]|[4.3 Regression] |Segmentation fault of |Segmentation fault with -O2 |compiled program with -O2 | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31030