public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/11835] New: Subject: g++ 3.3 loops using all virtual memory with unusual 'new' statement
@ 2003-08-06 17:03 gcc-bugzilla at gcc dot gnu dot org
2003-08-06 17:58 ` [Bug c++/11835] " pinskia at physics dot uc dot edu
0 siblings, 1 reply; 2+ messages in thread
From: gcc-bugzilla at gcc dot gnu dot org @ 2003-08-06 17:03 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11835
Summary: Subject: g++ 3.3 loops using all virtual memory with
unusual 'new' statement
Product: gcc
Version: 3.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pdubuc at cas dot org
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: sparc-sun-solaris2.8
GCC host triplet: sparc-sun-solaris2.8
GCC target triplet: sparc-sun-solaris2.8
This bug is simlar to #11282 in the GCC Bugzilla database, but It may have a
different cause. The following program causes g++ 3.3 to loop (with no
error or warning messages) using up all virtual memory.
int
main()
{
int i = 16;
char* heap_area = new char [i]();
}
Is line 5 valid C++ with the parens? I've never see new called this way, but
it compiled fine with g++ 2.95.3. If the parens are valid, what do they mean?
With g++ 3.2.3 I get the following error:
z.cc: In function `int main()':
z.cc:5: variable-sized object of type `char[i]' may not be initialized
With 3.3 the code compiles fine when the parens are removed from line 5 or if a literal constant is used in place of 'i'.
Environment:
System: SunOS pmd24awu 5.8 Generic_108528-16 sun4u sparc SUNW,Sun-Blade-100
Architecture: sun4
host: sparc-sun-solaris2.8
build: sparc-sun-solaris2.8
target: sparc-sun-solaris2.8
configured with: ../gcc-3.3/configure --prefix=/vol/gnu/gcc-3.3 --enable-shared --enable-threads --enable-cpp --enable-languages=c++ --with-gnu-as --with-as=/vol/gnu/gcc-3.3/bin/as --with-gnu-ld --with-ld=/vol/gnu/gcc-3.3/bin/ld --host=sparc-sun-solaris2.8
How-To-Repeat:
See Description.
------- Additional Comments From pdubuc at cas dot org 2003-08-06 17:03 -------
Fix:
See Description.
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug c++/11835] Subject: g++ 3.3 loops using all virtual memory with unusual 'new' statement
2003-08-06 17:03 [Bug c++/11835] New: Subject: g++ 3.3 loops using all virtual memory with unusual 'new' statement gcc-bugzilla at gcc dot gnu dot org
@ 2003-08-06 17:58 ` pinskia at physics dot uc dot edu
0 siblings, 0 replies; 2+ messages in thread
From: pinskia at physics dot uc dot edu @ 2003-08-06 17:58 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11835
pinskia at physics dot uc dot edu changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |DUPLICATE
------- Additional Comments From pinskia at physics dot uc dot edu 2003-08-06 17:58 -------
This is a dup of bug 11228 which is already fixed for 3.3.1 which should be released in the next
two days.
*** This bug has been marked as a duplicate of 11228 ***
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-08-06 17:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-06 17:03 [Bug c++/11835] New: Subject: g++ 3.3 loops using all virtual memory with unusual 'new' statement gcc-bugzilla at gcc dot gnu dot org
2003-08-06 17:58 ` [Bug c++/11835] " pinskia at physics dot uc dot edu
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).