Skip site navigation (1) Skip section navigation (2)

Function call hierarchy/path since getting the buffer until access its data

From: Waldecir Faria <fighter2929(at)hotmail(dot)com>
To: <pgsql-hackers(at)postgresql(dot)org>
Subject: Function call hierarchy/path since getting the buffer until access its data
Date: 2012-05-28 12:15:00
Message-ID: SNT137-W11904CBC8125B098E2A57FAC040@phx.gbl (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Good morning, I am doing a study about buffer management to improve the performance of one program that does heavy I/O operations. After looking and reading from different softwares' source codes/texts one friend suggested me to take a look at the PostgreSQL code. I already took a look at the PostgreSQL buffer management modules ( freelist.c and cia ) but now I am a bit confused how the buffer read/write works, I tried to see how PostgreSQL does to get, for example, a char array from one buffer. Looking at rawpage.c I think that I found a good example using the following function calls sequence starting at function get_raw_page_internal():

StrategyGetBuffer->BufferAlloc->ReadBuffer_Common ->ReadBufferExtended->BufferGetPage-> memcpy page to buf                                                                                        
But I need more examples or explanations to understand it better. Does anyone have more examples or can recommend me some article that says something about this?



pgsql-hackers by date

Next:From: Andres FreundDate: 2012-05-28 14:35:32
Subject: Re: WalSndWakeup() and synchronous_commit=off
Previous:From: Florian PflugDate: 2012-05-28 11:16:57
Subject: Re: [RFC] Interface of Row Level Security

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group