This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
advice on development path
- To: gcc at gcc dot gnu dot org
- Subject: advice on development path
- From: Erik Smith <ersmith at ucsd dot edu>
- Date: Sun, 11 Jun 2000 09:21:15 -0700
I've been trying to adapt my C++ project from NT to g++ on linux and in the
process discovering many things about the state of C++ compilers and about
the cost of the language in general. I am at the beginning of a large
development effort and I have two choices in front of me: C or C++. The
project requires building a server application where performance is
critical. The main problem I'm having with g++ is the much larger code
size incurred with exceptions (I haven't found a way around this yet) Here
are the rest of the pros and cons around each choice as I see it:
C Pros
- virtually bug free compilers everywhere
- small code size achieved with relative ease
C Cons
- more difficult to read and work with when you're used to C++
- no exception handling to simplify error management.
C++ Pros
- abstractions can help accelerate development (most useful to me are
encapsulation, templates, and STL)
- exceptions can help simplify interfaces and error handling
C++ Cons
- it can be difficult to write completely exception safe classes (see the
book Exceptional C++)
- g++ and other compilers have trouble generating compact code
- harder to find programmers with sufficient C++ experience
- inevitably get drawn into some compiler conformance issue or bug
I would appreciate any experienced opinions on what other people use for
mission critical projects. Also, does anyone have any experience with KAI
(I'm a bit leery of relying on them since they were acquired)
erik