Re: BlockNumber fixes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: BlockNumber fixes
Date: 2002-07-08 14:19:08
Message-ID: 17228.1026137948@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> I did some research on this and generated the following patch. I didn't
> find much in the way of problems except two vacuum.c fields that should
> probably be BlockNumber. freespace.c also has a numPages field in
> FSMRelation that is int. Should that be BlockNumber?

Not necessary, since the freespace map will never be large enough to
overflow a signed int (it wouldn't fit in the address space if it were).
I think that your changes in vacuum.c are probably unnecessary for the
same reason. I am generally wary of changing values from signed to
unsigned without close analysis of how they are used --- did you look
at *every* comparison involving these fields? How about arithmetic
that might compute a negative result?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2002-07-08 14:26:32 Re: DROP COLUMN Progress
Previous Message Tom Lane 2002-07-08 13:48:02 Re: Proposal: CREATE CONVERSION