public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
@ 2011-03-24  0:29 zsojka at seznam dot cz
  2011-03-24 12:20 ` [Bug c++/48265] [4.6/4.7 Regression] [C++0x] " rguenth at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: zsojka at seznam dot cz @ 2011-03-24  0:29 UTC (permalink / raw)
  To: gcc-bugs


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

           Summary: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in
                    value_dependent_expression_p) when variable is used
                    uninitialised
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: zsojka@seznam.cz


Looks similiar to PR46870, but this code is valid:

------- testcase.C -------
template < int > struct S
{
  S () { int i = i; i; };
};
--------------------------

Compiler output:
$ gcc -std=gnu++0x testcase.C
Program received signal SIGSEGV, Segmentation fault.
0x000000000054e883 in value_dependent_expression_p (expression=<value optimized
out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18065
18065     if (DECL_P (expression) && type_dependent_expression_p (expression))
(gdb) bt
#0  0x000000000054e883 in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18065
#1  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#2  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#3  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#4  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#5  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#6  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#7  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#8  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
#9  0x000000000054ea7e in value_dependent_expression_p (expression=<value
optimized out>) at /mnt/svn/gcc-trunk/gcc/cp/pt.c:18233
...


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
@ 2011-03-24 12:20 ` rguenth at gcc dot gnu.org
  2011-03-29 22:30 ` jason at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-03-24 12:20 UTC (permalink / raw)
  To: gcc-bugs


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

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |4.6.1


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
  2011-03-24 12:20 ` [Bug c++/48265] [4.6/4.7 Regression] [C++0x] " rguenth at gcc dot gnu.org
@ 2011-03-29 22:30 ` jason at gcc dot gnu.org
  2011-03-30  2:27 ` jason at gcc dot gnu.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2011-03-29 22:30 UTC (permalink / raw)
  To: gcc-bugs

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

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2011.03.29 21:14:12
                 CC|                            |jason at gcc dot gnu.org
         AssignedTo|unassigned at gcc dot       |jason at gcc dot gnu.org
                   |gnu.org                     |
     Ever Confirmed|0                           |1

--- Comment #1 from Jason Merrill <jason at gcc dot gnu.org> 2011-03-29 21:14:12 UTC ---
Got it.


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
  2011-03-24 12:20 ` [Bug c++/48265] [4.6/4.7 Regression] [C++0x] " rguenth at gcc dot gnu.org
  2011-03-29 22:30 ` jason at gcc dot gnu.org
@ 2011-03-30  2:27 ` jason at gcc dot gnu.org
  2011-03-30  2:35 ` jason at gcc dot gnu.org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2011-03-30  2:27 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> 2011-03-30 02:16:27 UTC ---
Author: jason
Date: Wed Mar 30 02:16:22 2011
New Revision: 171714

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=171714
Log:
    PR c++/48265
    * pt.c (value_dependent_expression_p) [VAR_DECL]: Make sure
    the variable is constant before looking at its initializer.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/regress/value-dep1.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c
    trunk/gcc/testsuite/ChangeLog


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
                   ` (2 preceding siblings ...)
  2011-03-30  2:27 ` jason at gcc dot gnu.org
@ 2011-03-30  2:35 ` jason at gcc dot gnu.org
  2011-03-30  2:38 ` jason at gcc dot gnu.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2011-03-30  2:35 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Jason Merrill <jason at gcc dot gnu.org> 2011-03-30 02:16:44 UTC ---
Author: jason
Date: Wed Mar 30 02:16:37 2011
New Revision: 171715

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=171715
Log:
    PR c++/48265
    * pt.c (value_dependent_expression_p) [VAR_DECL]: Make sure
    the variable is constant before looking at its initializer.

Added:
    branches/gcc-4_6-branch/gcc/testsuite/g++.dg/cpp0x/regress/value-dep1.C
Modified:
    branches/gcc-4_6-branch/gcc/cp/ChangeLog
    branches/gcc-4_6-branch/gcc/cp/pt.c
    branches/gcc-4_6-branch/gcc/testsuite/ChangeLog


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
                   ` (3 preceding siblings ...)
  2011-03-30  2:35 ` jason at gcc dot gnu.org
@ 2011-03-30  2:38 ` jason at gcc dot gnu.org
  2011-03-30  3:14 ` jason at gcc dot gnu.org
  2011-05-02 16:11 ` paolo.carlini at oracle dot com
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2011-03-30  2:38 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Jason Merrill <jason at gcc dot gnu.org> 2011-03-30 02:35:48 UTC ---
*** Bug 46870 has been marked as a duplicate of this bug. ***


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
                   ` (4 preceding siblings ...)
  2011-03-30  2:38 ` jason at gcc dot gnu.org
@ 2011-03-30  3:14 ` jason at gcc dot gnu.org
  2011-05-02 16:11 ` paolo.carlini at oracle dot com
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2011-03-30  3:14 UTC (permalink / raw)
  To: gcc-bugs

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

Jason Merrill <jason at gcc dot gnu.org> changed:

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

--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> 2011-03-30 02:36:43 UTC ---
Fixed for 4.6.1.


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

* [Bug c++/48265] [4.6/4.7 Regression] [C++0x] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised
  2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
                   ` (5 preceding siblings ...)
  2011-03-30  3:14 ` jason at gcc dot gnu.org
@ 2011-05-02 16:11 ` paolo.carlini at oracle dot com
  6 siblings, 0 replies; 8+ messages in thread
From: paolo.carlini at oracle dot com @ 2011-05-02 16:11 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from Paolo Carlini <paolo.carlini at oracle dot com> 2011-05-02 16:07:56 UTC ---
*** Bug 46871 has been marked as a duplicate of this bug. ***


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

end of thread, other threads:[~2011-05-02 16:11 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-24  0:29 [Bug c++/48265] New: [4.6/4.7 Regression] ICE: SIGSEGV (recursion in value_dependent_expression_p) when variable is used uninitialised zsojka at seznam dot cz
2011-03-24 12:20 ` [Bug c++/48265] [4.6/4.7 Regression] [C++0x] " rguenth at gcc dot gnu.org
2011-03-29 22:30 ` jason at gcc dot gnu.org
2011-03-30  2:27 ` jason at gcc dot gnu.org
2011-03-30  2:35 ` jason at gcc dot gnu.org
2011-03-30  2:38 ` jason at gcc dot gnu.org
2011-03-30  3:14 ` jason at gcc dot gnu.org
2011-05-02 16:11 ` paolo.carlini at oracle dot com

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).