bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: manywarnings: Overhaul documentation


From: Paul Eggert
Subject: Re: manywarnings: Overhaul documentation
Date: Mon, 5 Jun 2023 13:25:20 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0

On 2023-06-04 15:18, Bruno Haible wrote:

+Do this once with optimizations (@code{CPPFLAGS=-O2}) and once with no
+optimizations (@code{CPPFLAGS=-O0} or @code{CPPFLAGS=-ggdb}).

-ggdb shouldn't affect warnings, no?

More generally, the advice shouldn't recommend -O0 specifically; it should recommend whatever optimization options typically used. It's common to build with './configure --enable-gcc-warnings; make' and debug from there, and when one (rarely) compiles with unusual options to debug specially one can do something like "make CFLAGS='-ggdb -O0 -DDEBUG' WARN_CFLAGS=" or whatever. If this is the practice there's no need to worry about -O0 when tuning manywarnings.

I installed the attached to make the documentation a bit more general, so that it covers this common style too.

Attachment: 0001-manywarnings-more-nuance-about-optimization.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]