Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita9ed875

Browse files
committed
Code review for tqueue.c: fix memory leaks, speed it up, other fixes.
When doing record typmod remapping, tqueue.c did fresh catalog lookupsfor each tuple it processed, which was pretty horrible performance-wise(it seemed to about halve the already none-too-quick speed of bulk readsin parallel mode). Worse, it insisted on putting bits of that data intoTopMemoryContext, from where it never freed them, causing asession-lifespan memory leak. (I suppose this was coded with the ideathat the sender process would quit after finishing the query ---but the receiver uses the same code.)Restructure to avoid repetitive catalog lookups and to keep that datain a query-lifespan context, in or below the context where theTQueueDestReceiver or TupleQueueReader itself lives.Fix some other bugs such as continuing to use a tupledesc afterreleasing our refcount on it. Clean up cavalier datatype choices(typmods are int32, please, not int, and certainly not Oid). Improvecomments and error message wording.
1 parentf9e439b commita9ed875

File tree

1 file changed

+695
-447
lines changed

1 file changed

+695
-447
lines changed

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp