MCPcopy Create free account
hub / github.com/apache/cloudberry / FlushOneBuffer

Function FlushOneBuffer

src/backend/storage/buffer/bufmgr.c:3960–3975  ·  view source on GitHub ↗

* Flush a previously, shared or exclusively, locked and pinned buffer to the * OS. */

Source from the content-addressed store, hash-verified

3958 * OS.
3959 */
3960void
3961FlushOneBuffer(Buffer buffer)
3962{
3963 BufferDesc *bufHdr;
3964
3965 /* currently not needed, but no fundamental reason not to support */
3966 Assert(!BufferIsLocal(buffer));
3967
3968 Assert(BufferIsPinned(buffer));
3969
3970 bufHdr = GetBufferDescriptor(buffer - 1);
3971
3972 Assert(LWLockHeldByMe(BufferDescriptorGetContentLock(bufHdr)));
3973
3974 FlushBuffer(bufHdr, NULL);
3975}
3976
3977/*
3978 * ReleaseBuffer -- release the pin on a buffer

Callers 3

hash_xlog_init_meta_pageFunction · 0.85

Calls 2

LWLockHeldByMeFunction · 0.85
FlushBufferFunction · 0.85

Tested by

no test coverage detected