Re: Free Space Map data structure - Mailing list pgsql-hackers

From Dave Page
Subject Re: Free Space Map data structure
Date
Msg-id 937d27e10804080159i10e9bacckeeb7404ec5374835@mail.gmail.com
Whole thread Raw
In response to Re: Free Space Map data structure  ("Brendan Jurd" <direvus@gmail.com>)
List pgsql-hackers
On Tue, Apr 8, 2008 at 9:54 AM, Brendan Jurd <direvus@gmail.com> wrote:
>  If I understand your design correctly, this claim isn't true.  If the
>  topmost node reports 9 bytes free, could you not have seven pages each
>  with 1 byte free, and an eighth page with 2 bytes free?
>
>           9
>     4          5
>   2    2    2    3
>  1 1 1 1 1 1 1 2
>
>  So you'd actually end up walking two levels down the left hand side of
>  the tree, discovering not enough space, and then walking two levels
>  down the right hand side to again discover not enough space.

As I read it, each node takes the value of the largest child, not the
sum of the children.


-- 
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: "Brendan Jurd"
Date:
Subject: Re: Free Space Map data structure
Next
From: Zoltan Boszormenyi
Date:
Subject: Re: TRUNCATE TABLE with IDENTITY