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

Commit376c216

Browse files
committed
Update comment, generation mem contexts have a "keeper" block
The keeper block was introduced in commit1b0d9aa, but it forgotto update this comment.
1 parent8ba6fdf commit376c216

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

‎src/backend/utils/mmgr/generation.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -271,8 +271,10 @@ GenerationContextCreate(MemoryContext parent,
271271
* GenerationReset
272272
*Frees all memory which is allocated in the given set.
273273
*
274-
* The code simply frees all the blocks in the context - we don't keep any
275-
* keeper blocks or anything like that.
274+
* The initial "keeper" block (which shares a malloc chunk with the context
275+
* header) is not given back to the operating system though. In this way, we
276+
* don't thrash malloc() when a context is repeatedly reset after small
277+
* allocations.
276278
*/
277279
void
278280
GenerationReset(MemoryContextcontext)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp