[Bug c++/33401] Unwanted memset in default constructor

2007-09-12 Thread kbateman at seicorp dot com
--- Comment #5 from kbateman at seicorp dot com 2007-09-12 12:52 --- Whaddaya know. Section 5-16, Expressions: If the new-initializer is of the form (), default-initialization shall be performed (8.5); -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33401

[Bug c++/33401] Unwanted memset in default constructor

2007-09-12 Thread rguenth at gcc dot gnu dot org
--- Comment #4 from rguenth at gcc dot gnu dot org 2007-09-12 08:33 --- So, invalid. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added Status|UNC

[Bug c++/33401] Unwanted memset in default constructor

2007-09-11 Thread sebor at roguewave dot com
--- Comment #3 from sebor at roguewave dot com 2007-09-12 03:47 --- You remember correctly :) To avoid zeroing it out use 'new buffer' w/o the parentheses. -- sebor at roguewave dot com changed: What|Removed |Added

[Bug c++/33401] Unwanted memset in default constructor

2007-09-11 Thread pinskia at gcc dot gnu dot org
--- Comment #2 from pinskia at gcc dot gnu dot org 2007-09-12 00:45 --- I have to remember what C++ says here but I think it says buf gets zero'd. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33401

[Bug c++/33401] Unwanted memset in default constructor

2007-09-11 Thread kbateman at seicorp dot com
--- Comment #1 from kbateman at seicorp dot com 2007-09-11 22:32 --- Sorry, that a.s is from a run without -O2. The memset call is still in the -O2 output, though. a.s: ... movl$65536, (%esp) call_Znwj movl%eax, %ebx movl$65536, %edx