public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/31295]  New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4
@ 2007-03-21 14:19 burnus at gcc dot gnu dot org
  2007-03-23 20:15 ` [Bug fortran/31295] " tkoenig at alice-dsl dot net
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-03-21 14:19 UTC (permalink / raw)
  To: gcc-bugs

Found by valgrind:
gfortran gfortran.dg/eoshift.f90
valgrind a.out

==20986== Conditional jump or move depends on uninitialised value(s)
==20986==    at 0x4EC57D7: eoshift0 (eoshift0.c:115)
==20986==    by 0x4EC5D0A: _gfortran_eoshift0_4 (eoshift0.c:251)
==20986==    by 0x4009A7: MAIN__ (in
/projects/tob/gcc/gcc/testsuite/gfortran.dg/a.out)
==20986==    by 0x400A3B: main (fmain.c:22)

Similarly for:
- zero_sized_1.f90


-- 
           Summary: Uninitialized variable in libgfortran's
                    _gfortran_eoshift0_4
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: burnus at gcc dot gnu dot org


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
@ 2007-03-23 20:15 ` tkoenig at alice-dsl dot net
  2007-03-23 21:14 ` [Bug libfortran/31295] " fxcoudert at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: tkoenig at alice-dsl dot net @ 2007-03-23 20:15 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from tkoenig at alice-dsl dot net  2007-03-23 20:14 -------
The eoshift.f90 case is 'mostly harmless'.  We are doing calculations
with the value, but don't actually use this for anything.

We can "fix" this (cosmetic fix for valgrind, really) by
setting sstride[0] to an arbitray value that would cause
a segfault if the value was actually used for anything.


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug libfortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
  2007-03-23 20:15 ` [Bug fortran/31295] " tkoenig at alice-dsl dot net
@ 2007-03-23 21:14 ` fxcoudert at gcc dot gnu dot org
  2007-04-17 21:41 ` fxcoudert at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-03-23 21:14 UTC (permalink / raw)
  To: gcc-bugs



-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
          Component|fortran                     |libfortran
     Ever Confirmed|0                           |1
      Known to fail|                            |4.1.3 4.2.0 4.3.0
   Last reconfirmed|0000-00-00 00:00:00         |2007-03-23 21:14:33
               date|                            |
   Target Milestone|---                         |4.3.0


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug libfortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
  2007-03-23 20:15 ` [Bug fortran/31295] " tkoenig at alice-dsl dot net
  2007-03-23 21:14 ` [Bug libfortran/31295] " fxcoudert at gcc dot gnu dot org
@ 2007-04-17 21:41 ` fxcoudert at gcc dot gnu dot org
  2007-05-22 16:05 ` patchapp at dberlin dot org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-04-17 21:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from fxcoudert at gcc dot gnu dot org  2007-04-17 22:41 -------
(In reply to comment #1)
> We can "fix" this (cosmetic fix for valgrind, really) by
> setting sstride[0] to an arbitray value that would cause
> a segfault if the value was actually used for anything.

I'd go for (-1). Patch pre-approved.

PS: if you go for it before I have time, would you mind testing & commiting my
fix for PR31296 as well?


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |burnus at gcc dot gnu dot
                   |dot org                     |org
             Status|NEW                         |ASSIGNED


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug libfortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2007-04-17 21:41 ` fxcoudert at gcc dot gnu dot org
@ 2007-05-22 16:05 ` patchapp at dberlin dot org
  2007-05-22 16:20 ` burnus at gcc dot gnu dot org
  2007-05-22 16:20 ` burnus at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: patchapp at dberlin dot org @ 2007-05-22 16:05 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from patchapp at dberlin dot org  2007-05-22 17:05 -------
Subject: Bug number PR31295

A patch for this bug has been added to the patch tracker.
The mailing list url for the patch is
http://gcc.gnu.org/ml/gcc-patches/2007-05/msg01461.html


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug libfortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2007-05-22 16:05 ` patchapp at dberlin dot org
@ 2007-05-22 16:20 ` burnus at gcc dot gnu dot org
  2007-05-22 16:20 ` burnus at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-05-22 16:20 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from burnus at gcc dot gnu dot org  2007-05-22 17:19 -------
Subject: Bug 31295

Author: burnus
Date: Tue May 22 16:19:09 2007
New Revision: 124948

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=124948
Log:
2007-05-22  Tobias Burnus  <burnus@net-b.de>

       PR libgfortran/31295
       * intrinsics/eoshift0.c (eoshift0): Silence uninitialized warning.
       * intrinsics/eoshift2.c (eoshift2): Ditto.


Modified:
    trunk/libgfortran/ChangeLog
    trunk/libgfortran/intrinsics/eoshift0.c
    trunk/libgfortran/intrinsics/eoshift2.c


------- Comment #5 from burnus at gcc dot gnu dot org  2007-05-22 17:19 -------
Fixed


-- 

burnus at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug libfortran/31295] Uninitialized variable in libgfortran's _gfortran_eoshift0_4
  2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2007-05-22 16:20 ` burnus at gcc dot gnu dot org
@ 2007-05-22 16:20 ` burnus at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-05-22 16:20 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from burnus at gcc dot gnu dot org  2007-05-22 17:19 -------
Subject: Bug 31295

Author: burnus
Date: Tue May 22 16:19:09 2007
New Revision: 124948

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=124948
Log:
2007-05-22  Tobias Burnus  <burnus@net-b.de>

       PR libgfortran/31295
       * intrinsics/eoshift0.c (eoshift0): Silence uninitialized warning.
       * intrinsics/eoshift2.c (eoshift2): Ditto.


Modified:
    trunk/libgfortran/ChangeLog
    trunk/libgfortran/intrinsics/eoshift0.c
    trunk/libgfortran/intrinsics/eoshift2.c


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2007-05-22 16:20 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-21 14:19 [Bug fortran/31295] New: Uninitialized variable in libgfortran's _gfortran_eoshift0_4 burnus at gcc dot gnu dot org
2007-03-23 20:15 ` [Bug fortran/31295] " tkoenig at alice-dsl dot net
2007-03-23 21:14 ` [Bug libfortran/31295] " fxcoudert at gcc dot gnu dot org
2007-04-17 21:41 ` fxcoudert at gcc dot gnu dot org
2007-05-22 16:05 ` patchapp at dberlin dot org
2007-05-22 16:20 ` burnus at gcc dot gnu dot org
2007-05-22 16:20 ` burnus at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).