This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: verbose terminate() on by default


On Mon, Dec 23, 2002 at 01:26:21PM -0200, Alexandre Oliva wrote:
> On Dec 23, 2002, Phil Edwards <phil@jaj.com> wrote:
> 
> > I can't find anywhere in the standard that prohibits us from doing so.
> 
> The one reason I can think of to not do it this way is that it may
> impact the size of applications in ways that would be hard to revert.

We're changing the initialization of an existing pointer-to-function (the
currently installed handler), but not definding anything new.  We're also
generating a reference to a function all the time where we weren't before,
but that function is in the library, not the final executable.  Am I
missing anything else?

Using a testcase of

    #include <exception>

    int main() { throw 42; }

Before / normal terminate:

    % ls -l a.out
    -rwxr-xr-x    1 pme      pme          4997 Dec 23 10:46 a.out
    % size a.out
       text    data     bss     dec     hex filename
       1262     296      12    1570     622 a.out

After / verbose terminate:

    % ls -l a.out
    -rwxr-xr-x    1 pme      pme          4965 Dec 23 10:45 a.out
    % size a.out
       text    data     bss     dec     hex filename
       1216     296      12    1524     5f4 a.out

Hmmm.  I wouldn't have expected the size to get smaller, either.


Phil

-- 
I would therefore like to posit that computing's central challenge, viz. "How
not to make a mess of it," has /not/ been met.
                                                 - Edsger Dijkstra, 1930-2002


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]