Commit 6ebeeae
committed
Cache typarray for fast lookups in binary upgrade mode
When upgrading a large schema it adds significant overhead to perform
individual catalog lookups per relation in order to retrieve Oid for
preserving Oid calls. This instead adds the typarray to the TypeInfo
cache which then allows for fast lookups using the existing API. A
35% reduction of pg_dump runtime in binary upgrade mode was observed
with this change.
Reviewed-by: Nathan Bossart <nathandbossart@gmail.com>
Discussion: https://postgr.es/m/8F1F1E1D-D17B-4B33-B014-EDBCD15F3F0B@yesql.se1 parent 4d5111b commit 6ebeeae
2 files changed
+9
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5412 | 5412 | | |
5413 | 5413 | | |
5414 | 5414 | | |
| 5415 | + | |
5415 | 5416 | | |
5416 | 5417 | | |
5417 | 5418 | | |
5418 | 5419 | | |
5419 | 5420 | | |
5420 | 5421 | | |
5421 | | - | |
5422 | | - | |
5423 | | - | |
5424 | | - | |
5425 | | - | |
5426 | | - | |
5427 | | - | |
5428 | | - | |
5429 | | - | |
5430 | | - | |
5431 | | - | |
| 5422 | + | |
| 5423 | + | |
5432 | 5424 | | |
5433 | 5425 | | |
5434 | 5426 | | |
| |||
5910 | 5902 | | |
5911 | 5903 | | |
5912 | 5904 | | |
| 5905 | + | |
5913 | 5906 | | |
5914 | 5907 | | |
5915 | 5908 | | |
| |||
5930 | 5923 | | |
5931 | 5924 | | |
5932 | 5925 | | |
5933 | | - | |
| 5926 | + | |
5934 | 5927 | | |
5935 | 5928 | | |
5936 | 5929 | | |
| |||
5957 | 5950 | | |
5958 | 5951 | | |
5959 | 5952 | | |
| 5953 | + | |
5960 | 5954 | | |
5961 | 5955 | | |
5962 | 5956 | | |
| |||
5989 | 5983 | | |
5990 | 5984 | | |
5991 | 5985 | | |
| 5986 | + | |
| 5987 | + | |
5992 | 5988 | | |
5993 | 5989 | | |
5994 | 5990 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
| 203 | + | |
203 | 204 | | |
204 | 205 | | |
205 | 206 | | |
| |||
0 commit comments