public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/103045] New: False report substring out of bounds with -fbounds-check
@ 2021-11-02 12:32 krefson at gmail dot com
  2021-11-02 13:05 ` [Bug fortran/103045] " dominiq at lps dot ens.fr
  2021-11-02 18:33 ` anlauf at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: krefson at gmail dot com @ 2021-11-02 12:32 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103045

            Bug ID: 103045
           Summary: False report substring out of bounds with
                    -fbounds-check
           Product: gcc
           Version: 10.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: krefson at gmail dot com
  Target Milestone: ---

Created attachment 51723
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51723&action=edit
Test program

The attached (correct) program generates an incorrect report of a substring
bounds error when compiled with -fbounds-check.

$ gfortran-10 -g -fbounds-check -fbacktrace debugtest.f90
$ ./a.out
Fortran runtime error: Substring out of bounds: lower bound (0) of 'sf_string'
is less than one

Error termination. Backtrace:
#0  0x7f9a46a8a744 in ???
#1  0x7f9a46a8b219 in ???
#2  0x7f9a46a8b82a in ???
#3  0x4009b4 in debugtest
        at /home/kr/CASTEP/Compiler_BUGS/Gfortran_Debug_False/debugtest.f90:10
#4  0x400c86 in main
        at /home/kr/CASTEP/Compiler_BUGS/Gfortran_Debug_False/debugtest.f90:14

This occurs with gcc-fortran version 8, 9, 10.

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

* [Bug fortran/103045] False report substring out of bounds with -fbounds-check
  2021-11-02 12:32 [Bug fortran/103045] New: False report substring out of bounds with -fbounds-check krefson at gmail dot com
@ 2021-11-02 13:05 ` dominiq at lps dot ens.fr
  2021-11-02 18:33 ` anlauf at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: dominiq at lps dot ens.fr @ 2021-11-02 13:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103045

Dominique d'Humieres <dominiq at lps dot ens.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2021-11-02
             Status|UNCONFIRMED                 |WAITING
     Ever confirmed|0                           |1

--- Comment #1 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
This has been fixed in  r10-10223, 11 and 12.

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

* [Bug fortran/103045] False report substring out of bounds with -fbounds-check
  2021-11-02 12:32 [Bug fortran/103045] New: False report substring out of bounds with -fbounds-check krefson at gmail dot com
  2021-11-02 13:05 ` [Bug fortran/103045] " dominiq at lps dot ens.fr
@ 2021-11-02 18:33 ` anlauf at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: anlauf at gcc dot gnu.org @ 2021-11-02 18:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103045

anlauf at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|---                         |DUPLICATE
                 CC|                            |anlauf at gcc dot gnu.org

--- Comment #2 from anlauf at gcc dot gnu.org ---
Looks very similar to pr98490, which is fixed on all open branches.

*** This bug has been marked as a duplicate of bug 98490 ***

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

end of thread, other threads:[~2021-11-02 18:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-02 12:32 [Bug fortran/103045] New: False report substring out of bounds with -fbounds-check krefson at gmail dot com
2021-11-02 13:05 ` [Bug fortran/103045] " dominiq at lps dot ens.fr
2021-11-02 18:33 ` anlauf at gcc dot gnu.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).