develooper Front page | perl.perl5.porters | Postings from December 2008

Re: [PATCH] -g isn't always -g

Thread Previous | Thread Next
From:
Reini Urban
Date:
December 24, 2008 08:30
Subject:
Re: [PATCH] -g isn't always -g
Message ID:
495263A3.9080705@x-ray.at
Jarkko Hietaniemi schrieb:
> In Tru64 if one cranks up the optimization to -O4, one also needs to
> crank up the debugging to -g3, since -g is equivalent to -g2, which
> is not enough for -O4.  The problem is that the -g might be added
> by Configure when doing -DDEBUGGING/-DEBUGGING, so looking at optimize
> and/or ccflags in the hints file is not enough.
> 
> I could have just tweaked this in hints/dec_osf.sh, but I would have
> just ended up duplicating much of the the Configure DEBUGGING logic.
> Therefore I introduced a new Configure variable 'debugging', which
> defaults to '-g', but can be whatever. I don't know that it's necessary
> to store it in config.sh, this patch doesn't, but I'll leave it to
> Configuremeister to decide.

Serious debugging on dwarf needs -g3 anyway, otherwise you get no 
macroexpansion. Accessing sv's or op's without macros causes headaches.

I would propose to raise -g to -g3 on all gcc dwarf capable platforms 
per default.

I always override it with -DDEBUGGING -Doptimize=-g3
-- 
Reini

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About