Bug 19299 - [4.0 Regression] ICE with volatile non-PODs pointers
Summary: [4.0 Regression] ICE with volatile non-PODs pointers
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: 4.0.0
Assignee: Mark Mitchell
URL:
Keywords: ice-checking, ice-on-valid-code
: 19297 19534 (view as bug list)
Depends on:
Blocks: 19297
  Show dependency treegraph
 
Reported: 2005-01-06 19:51 UTC by Andrew Pinski
Modified: 2005-02-15 22:01 UTC (History)
5 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2005-01-06 20:06:40


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Pinski 2005-01-06 19:51:26 UTC
struct V
{
 virtual void f() = 0;
};
void execute(V volatile* p)
{
  p->V::~V();
}
Comment 1 Andrew Pinski 2005-01-06 20:01:03 UTC
*** Bug 19297 has been marked as a duplicate of this bug. ***
Comment 2 Andrew Pinski 2005-01-06 20:06:40 UTC
Confirmed because this was just a reduction of PR 19297 and I had thought we needed two bugs for 
that but it was kindly already filed.
Comment 3 Andrew Pinski 2005-01-08 22:53:09 UTC
: Search converges between 2004-05-11-trunk (#454) and 2004-05-14-trunk (#455).
: Search converges between 2003-06-25-ssa (#14) and 2003-06-26-ssa (#15).
Comment 4 Andrew Pinski 2005-01-19 18:39:01 UTC
*** Bug 19534 has been marked as a duplicate of this bug. ***
Comment 5 Giovanni Bajo 2005-01-20 02:09:06 UTC
For the log, this is blocking Boost (test: python/bienstman1).
Comment 6 Diego Novillo 2005-01-20 02:17:42 UTC
Works for me.  What's the problem?

$ gcc/xgcc -Bgcc -O2 -c pr19299.C --version
xgcc (GCC) 4.0.0 20050117 (experimental)
Copyright (C) 2005 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Comment 7 Andrew Pinski 2005-01-20 02:23:17 UTC
(In reply to comment #6)
> Works for me.  What's the problem?
Or does it, see below. 

> $ gcc/xgcc -Bgcc -O2 -c pr19299.C --version
> xgcc (GCC) 4.0.0 20050117 (experimental)
> ....

--version makes the compiler to do nothing except for printing out the version.

It still ICEs for me:
[zhivago:gcc/objdir/gcc] pinskia% ./xgcc -B. t43.cc 
t43.cc: In function 'void execute(volatile V*)':
t43.cc:7: internal compiler error: in create_tmp_var, at gimplify.c:368
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

GNU C++ version 4.0.0 20050119 (experimental) (powerpc-apple-darwin7.7.0)
Comment 8 Diego Novillo 2005-01-20 02:32:24 UTC
Subject: Re:  [4.0 Regression] ICE with volatile non-PODs pointers

pinskia at gcc dot gnu dot org wrote:

>>$ gcc/xgcc -Bgcc -O2 -c pr19299.C --version
>>xgcc (GCC) 4.0.0 20050117 (experimental)
>>....
> 
> 
> --version makes the compiler to do nothing except for printing out the version.
> 
I know.  I collapsed both outputs for brevity.

Never mind.  I was using a --disabled-checking binary.


Diego.
Comment 9 Volker Reichelt 2005-02-10 21:53:40 UTC
Fixed on mainline (probably by one of your recent patches, Mark).

Do you want this as a testcase?
Comment 10 Mark Mitchell 2005-02-10 22:13:23 UTC
Yes, a test case for this would be good.

Thanks!
Comment 11 GCC Commits 2005-02-19 20:37:03 UTC
Subject: Bug 19299

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	reichelt@gcc.gnu.org	2005-02-19 20:36:57

Modified files:
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/g++.dg/inherit: volatile1.C 
	gcc/testsuite/g++.dg/template: dtor4.C 

Log message:
	PR c++/19299
	* g++.dg/inherit/volatile1.C: New test.
	
	PR c++/19440
	* g++.dg/template/dtor4.C: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.5057&r2=1.5058
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/inherit/volatile1.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/dtor4.C.diff?cvsroot=gcc&r1=NONE&r2=1.1