summaryrefslogtreecommitdiff
path: root/src/backend/utils/Gen_fmgrtab.pl
diff options
context:
space:
mode:
authorAndres Freund2018-10-16 21:51:18 +0000
committerAndres Freund2018-10-16 21:51:18 +0000
commit28d750c0cd5b3cea0dfbc84cce24e30f5c2eb966 (patch)
tree240db976e1466e5dbb910f2751f4059cc203c16a /src/backend/utils/Gen_fmgrtab.pl
parent68fc227dd0737f38295f3dee0c10268ad11a5150 (diff)
Reorder FmgrBuiltin members, saving 25% in size.
That's worth it, as fmgr_builtins is frequently accessed, and as fmgr_builtins is one of the biggest constant variables in a backend. On most 64bit systems this will change the size of the struct from 32byte to 24bytes. While that could make indexing into the array marginally more expensive, the higher cache hit ratio is worth more, especially because these days fmgr_builtins isn't searched with a binary search anymore (c.f. 212e6f34d5). Discussion: https://postgr.es/m/[email protected]
Diffstat (limited to 'src/backend/utils/Gen_fmgrtab.pl')
-rw-r--r--src/backend/utils/Gen_fmgrtab.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/utils/Gen_fmgrtab.pl b/src/backend/utils/Gen_fmgrtab.pl
index fa30436895b..ca282913552 100644
--- a/src/backend/utils/Gen_fmgrtab.pl
+++ b/src/backend/utils/Gen_fmgrtab.pl
@@ -230,7 +230,7 @@ my $fmgr_count = 0;
foreach my $s (sort { $a->{oid} <=> $b->{oid} } @fmgr)
{
print $tfh
- " { $s->{oid}, \"$s->{prosrc}\", $s->{nargs}, $bmap{$s->{strict}}, $bmap{$s->{retset}}, $s->{prosrc} }";
+ " { $s->{oid}, $s->{nargs}, $bmap{$s->{strict}}, $bmap{$s->{retset}}, \"$s->{prosrc}\", $s->{prosrc} }";
$fmgr_builtin_oid_index[ $s->{oid} ] = $fmgr_count++;