public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/18192] New: Serious Performance Bug depending on a donothing destructor declaration
@ 2004-10-28 10:31 dkouroun at mailbox dot gr
  2004-10-28 10:34 ` [Bug c++/18192] " dkouroun at mailbox dot gr
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: dkouroun at mailbox dot gr @ 2004-10-28 10:31 UTC (permalink / raw)
  To: gcc-bugs

Dear GCC Team, 
I have experienced a serious performance bug 
with g++-3.4.2. In the attached code you can 
see the source code which is quite simple. In 
the file TypeDefinitions.h I use some typedef 
statements to be able play with different types. 
 
The problem is in file FiniteElementTypes.h!!! 
The one and only class in that file has a 
destructor declaration : 
 
public: 
  ~FiniteElement() {} 
 
When that destructor is commented out the program 
in my Sony-VAIO pentium4 2.66GHz needs almost 
4.450 seconds to run. When this destructor is not 
commented out the program needs 7.350 seconds to run. 
Even worse, when the destructor is not commented out 
and I change in TypeDefinitions.h the type Real from 
cRref to: 
 
typedef cR Real; 
 
the program needs 10.540 seconds to run. If I go to 
the file AsmExprOperators.h and having 
 
typedef cR Real; 
 
in Typedefinitions, I change all operators() from 
 
==>inline R operator()(indexType i, Real x, Real y, Real z) const 
 
to 
 
==>inline R operator()(indexType i, Real& x, Real& y, Real& z) const 
 
then the program again needs 7.300 seconds to run. 
 
Of course if I comment out the destructor declaration from the 
class FiniteElement then the program needs only 4.430 seconds to run. 
 
SuSE Linux 9.0 gcc-3.3.1 is insensitive to the destructor declaration 
but it needs almost 29.800 seconds! 
 
Intel ICC compiler though version 8.1.022 is also insensitive 
to the destructor declaration and it needs only 4.300 seconds!

-- 
           Summary: Serious Performance Bug depending on a donothing
                    destructor declaration
           Product: gcc
           Version: 3.4.2
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dkouroun at mailbox dot gr
                CC: gcc-bugs at gcc dot gnu dot org
  GCC host triplet: SuSE 9.0


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


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

end of thread, other threads:[~2005-09-15 19:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-28 10:31 [Bug c++/18192] New: Serious Performance Bug depending on a donothing destructor declaration dkouroun at mailbox dot gr
2004-10-28 10:34 ` [Bug c++/18192] " dkouroun at mailbox dot gr
2004-11-24 11:57 ` dkouroun at mailbox dot gr
2004-11-24 18:27 ` pinskia at gcc dot gnu dot org
2004-11-25 10:04 ` dkouroun at mailbox dot gr
2005-09-15 19:18 ` jason at gcc dot gnu dot org

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