Re: PostgreSQL on 64 bit Linux

Поиск
Список
Период
Сортировка
От mark@mark.mielke.cc
Тема Re: PostgreSQL on 64 bit Linux
Дата
Msg-id 20060821131646.GB15841@mark.mielke.cc
обсуждение исходный текст
Ответ на Re: PostgreSQL on 64 bit Linux  (Douglas McNaught <doug@mcnaught.org>)
Ответы Re: PostgreSQL on 64 bit Linux
Re: PostgreSQL on 64 bit Linux
Re: PostgreSQL on 64 bit Linux
Список pgsql-hackers
On Sun, Aug 20, 2006 at 11:00:26PM -0400, Douglas McNaught wrote:
> mark@mark.mielke.cc writes:
> > Is there an interest, or any active project to examine PostgreSQL in
> > the area of 64-bit processors? Has it already been done? I don't recall
> > seeing a reference to it in my travels. I'm also not sure on what to
> > expect for results, as the territory is still new. 64-bit processors
> > have existed for a while, but 32-bit processors have been the popular
> > choice, making 64-bit support an after thought?
> I find this question a bit amusing, since PG has run on 64-bit
> architectures such as MIPS, Sparc, Alpha and PA-RISC for quite a while
> now. :)

I don't think so. Software can be designed to take best advantage of
hardware. Recompiling it for a different architecture, running test
cases, and declaring support, is not the same as optimizing for.

> As I said in a private email to Naz, the main advantage I think you'd
> see from 64-bit is the ability to run with more than 2GB or so of
> shared buffers on a system with lots of RAM.  Whether you'd want to do
> that, or let the OS do most of the buffering, is an open question...

This is what I mean by after thought. PostgreSQL is designed for
32-bit processors. Which is fine. I'm not complaining. The question
was whether there is an interest in pursuing 64-bit specific
optimizations. In the PostgreSQL code, a quick check points me only to
"has long int 64" as a 64-bit source code #ifdef. Of the six places
that reference this, five of them actually slow down the code, as they
check for overflow of the 'long int' result beyond 4 bytes of
data. The sixth place is used to define the 64-bit type in use by
PostgreSQL, which I suspect is infrequently used.

I believe the answer is no. No or few 64-bit optimization possibilities
have been chased down, probably because some or many of these would:
   1) require significant re-architecture
   2) reduce the performance in a 32-bit world

It's a question that only half interests me. As with most projects, I
don't think the projects are ready to re-architect for this
purpose. Perhaps once 50%+ of people are running PostgreSQL in 64-bit
mode, the question will be more serious to more people.

As a half interesting question, I'm defending it as a valid question.
Please don't write it off, but it is fine to say "not yet, we have more
important things to work on".

Cheers,
mark

-- 
mark@mielke.cc / markm@ncf.ca / markm@nortel.com     __________________________
.  .  _  ._  . .   .__    .  . ._. .__ .   . . .__  | Neighbourhood Coder
|\/| |_| |_| |/    |_     |\/|  |  |_  |   |/  |_   | 
|  | | | | \ | \   |__ .  |  | .|. |__ |__ | \ |__  | Ottawa, Ontario, Canada
 One ring to rule them all, one ring to find them, one ring to bring them all                      and in the darkness
bindthem...
 
                          http://mark.mielke.cc/



В списке pgsql-hackers по дате отправления:

Предыдущее
От: mark@mark.mielke.cc
Дата:
Сообщение: Re: PostgreSQL on 64 bit Linux
Следующее
От: Paul Silveira
Дата:
Сообщение: Re: snapshot replication with pg_dump