1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Allow float8, int8, and related datatypes to be passed by value on machines

where Datum is 8 bytes wide.  Since this will break old-style C functions
(those still using version 0 calling convention) that have arguments or
results of these types, provide a configure option to disable it and retain
the old pass-by-reference behavior.  Likewise, provide a configure option
to disable the recently-committed float4 pass-by-value change.

Zoltan Boszormenyi, plus configurability stuff by me.
This commit is contained in:
Tom Lane
2008-04-21 00:26:47 +00:00
parent be939544a6
commit 8472bf7a73
36 changed files with 661 additions and 243 deletions

View File

@ -1,4 +1,4 @@
<!-- $PostgreSQL: pgsql/doc/src/sgml/installation.sgml,v 1.306 2008/03/30 04:08:15 neilc Exp $ -->
<!-- $PostgreSQL: pgsql/doc/src/sgml/installation.sgml,v 1.307 2008/04/21 00:26:44 tgl Exp $ -->
<chapter id="installation">
<title><![%standalone-include[<productname>PostgreSQL</>]]>
@ -1032,6 +1032,40 @@ su - postgres
</listitem>
</varlistentry>
<varlistentry>
<term><option>--disable-float4-byval</option></term>
<listitem>
<para>
Disable passing float4 values <quote>by value</>, causing them
to be passed <quote>by reference</> instead. This option costs
performance, but may be needed for compatibility with old
user-defined functions that are written in C and use the
<quote>version 0</> calling convention. A better long-term
solution is to update any such functions to use the
<quote>version 1</> calling convention.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>--disable-float8-byval</option></term>
<listitem>
<para>
Disable passing float8 values <quote>by value</>, causing them
to be passed <quote>by reference</> instead. This option costs
performance, but may be needed for compatibility with old
user-defined functions that are written in C and use the
<quote>version 0</> calling convention. A better long-term
solution is to update any such functions to use the
<quote>version 1</> calling convention.
Note that this option affects not only float8, but also int8 and some
related types such as timestamp.
On 32-bit platforms, <option>--disable-float8-byval</> is the default
and it is not allowed to select <option>--enable-float8-byval</>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>--disable-segmented-files</option></term>
<listitem>