[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fri, 22 Mar 2002 18:32:37 +0100
Nicola Pero wrote:
> Just an idea - should we perhaps keep the -O2 flag even when debug=yes is
> used ?
> That would make sure when you use debug=yes you get all the warnings ...
> <and I think if you use debug=yes, it's because you are debugging and
> definitely you want as many useful warnings as possible - in particular,
> you *do* want the flow analysis warnings>
> I'm quite sure gcc is supposed to be able to manage `-O2 -g' pretty well
> ... but perhaps it might make things more difficult when debugging ?
> Does -O2 cause problems when debugging ?
It does make debugging trickier in some cases. Due to code reordering
you can't always trust the line number, and variables might seem to have
the wrong value. However, I've modified my copy of gnustep-make to
compile everything with '-O2 -g' normally (ie. with debug=no), and this
has worked well. I think the tradeoff is worth it.
Also, I think it might be a good idea to always compile with -Wall.
- Alexander Malmberg
- Re: PSclip, Nicola Pero, 2002/03/22
- Re: PSclip,
Alexander Malmberg <=