Re: Don't removes/recycles WAL files at all - Mailing list pgsql-general

From Tom Lane
Subject Re: Don't removes/recycles WAL files at all
Date
Msg-id 27361.1059622830@sss.pgh.pa.us
Whole thread Raw
In response to Re: Don't removes/recycles WAL files at all  (Michael Govorun <mike@shpion.ru>)
Responses Re: Don't removes/recycles WAL files at all
List pgsql-general
Michael Govorun <mike@shpion.ru> writes:
> I've found answer! Postgresql have been compiled with aggressive
> optimizations:
> gcc version egcs-2.91.66
> CFLAGS='-O9 -funroll-loops -ffast-math -malign-double -mcpu=pentiumpro
> -march=pentiumpro -fomit-frame-pointer -fno-exceptions'

> After recompiling server with -O2 WAL recycling properly. But I got
> many errors after installing recompiled server and had to dump
> database with "optimized" postgres and restore with -O2 version.

Yeah, adding or removing -malign-double would change the layout of our
on-disk data structures, so it's no surprise you'd need to dump and
reload for that.

Also, -ffast-math is known to be Evil.  I thought we had a check to
prevent that (looks ...) yeah we do; how'd you get by this check in
timestamp.c?

/*
 * gcc's -ffast-math switch breaks routines that expect exact results from
 * expressions like timeval / 3600, where timeval is double.
 */
#ifdef __FAST_MATH__
#error -ffast-math is known to break this code
#endif

As for the other stuff, it theoretically should work, but isn't
egcs-2.91.66 rather old and buggy?  Perhaps a newer gcc would work
better.

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Don't removes/recycles WAL files at all
Next
From: Tom Lane
Date:
Subject: Re: hexadecimal to decimal