public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Optimizing of explicit temporary storage
@ 2004-10-10 21:51 Richard Guenther
  2004-10-11  4:34 ` Mike Stump
  0 siblings, 1 reply; 22+ messages in thread
From: Richard Guenther @ 2004-10-10 21:51 UTC (permalink / raw)
  To: gcc

Is it legal for a conforming C++ compiler to optimize away storage 
allocation / deallocation?  Like in

#include <new>

void foo(void)
{
         int *x = new(std::nothrow) int;
         delete x;
}

is it allowed to kill the new and delete statements?  Would it be 
allowed to do this for the throwing version of new, too?

Thanks,
Richard.

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

end of thread, other threads:[~2004-10-13 23:57 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-10 21:51 Optimizing of explicit temporary storage Richard Guenther
2004-10-11  4:34 ` Mike Stump
2004-10-11  7:11   ` Richard Guenther
2004-10-12  7:38     ` Mark Mitchell
2004-10-12  8:40       ` Florian Weimer
2004-10-12  9:37         ` Mark Mitchell
2004-10-12 11:59           ` Robert Dewar
2004-10-12 12:19             ` Mark Mitchell
2004-10-12 13:10               ` Robert Dewar
2004-10-12 19:44           ` Mike Stump
2004-10-13  2:27           ` Geoffrey Keating
2004-10-13  3:42             ` Daniel Berlin
2004-10-13  9:18               ` Chris Lattner
2004-10-13 10:47                 ` Kai Henningsen
2004-10-13 13:22                 ` Daniel Berlin
2004-10-13 16:06                   ` Chris Lattner
2004-10-13 11:45           ` Nick Ing-Simmons
2004-10-13 13:02             ` Giovanni Bajo
2004-10-13 13:12               ` Nick Ing-Simmons
2004-10-14  4:21             ` Mike Stump
2004-10-12  9:02       ` Kai Henningsen
2004-10-12 19:36         ` Mike Stump

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