Re: Patch - Debug builds without optimization

Поиск
Список
Период
Сортировка
От Florian Pflug
Тема Re: Patch - Debug builds without optimization
Дата
Msg-id D8E087E5-B932-458E-85A0-A54D176EFB0A@phlo.org
обсуждение исходный текст
Ответ на Patch - Debug builds without optimization  (Radosław Smogura <rsmogura@softperience.eu>)
Ответы Re: Patch - Debug builds without optimization  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Jun16, 2011, at 14:30 , Radosław Smogura wrote:
> I'm sending following patch which disables optimization when --enable-debug is passed. It was nasty (for me, at
least)that debug build required passing of CFLAGS with -O0 to get nice traceable code. 

Unfortunately, with some compilers (gcc, I'm looking at you) you get considerably fewer warnings with -O0 than with
-O1,even if you specify -Wall. The reason seems to be that some of the warnings need information produces by some of
theoptimization passes. 

I usually use -O1 for debug builds, these are usually still at least somewhat debuggable with gdb.

best regards,
Florian Pflug



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Radosław Smogura
Дата:
Сообщение: Re: Patch - Debug builds without optimization
Следующее
От: Leonardo Francalanci
Дата:
Сообщение: Re: use less space in xl_xact_commit patch