diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2012-05-25 14:35:47 -0400 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2012-05-25 14:35:47 -0400 |
| commit | 965d76f972bec5595e84a8e8567636cb3ba7a1f2 (patch) | |
| tree | ad91f9a04d0866e1bd47e73052964a51848c4c33 /contrib/pg_stat_statements/pg_stat_statements.c | |
| parent | c676f835b544d73b3e75d994000d586f878fcb21 (diff) | |
Use binary search instead of brute-force scan in findNamespace().
The previous coding presented a significant bottleneck when dumping
databases containing many thousands of schemas, since the total time
spent searching would increase roughly as O(N^2) in the number of objects.
Noted by Jeff Janes, though I rewrote his proposed patch to use the
existing findObjectByOid infrastructure.
Since this is a longstanding performance bug, backpatch to all supported
versions.
Diffstat (limited to 'contrib/pg_stat_statements/pg_stat_statements.c')
0 files changed, 0 insertions, 0 deletions
