Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 3aafc03

Browse files
committedAug 16, 2021
Reduce memory consumption for pending invalidation messages.
The existing data structures in inval.c are fairly inefficient for the common case of a command or subtransaction that registers a small number of cache invalidation events. While this doesn't matter if we commit right away, it can build up to a lot of bloat in a transaction that contains many DDL operations. By making a few more assumptions about the expected use-case, we can switch to a representation using densely-packed arrays. Although this eliminates some data-copying, it doesn't seem to make much difference time-wise. But the space consumption decreases substantially. Patch by me; thanks to Nathan Bossart for review. Discussion: https://postgr.es/m/2380555.1622395376@sss.pgh.pa.us
1 parent 069d33d commit 3aafc03

File tree

1 file changed

+286
-228
lines changed

1 file changed

+286
-228
lines changed
 

0 commit comments

Comments
 (0)
Please sign in to comment.