pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alan Stange <stange@rentec.com>
To: mark@mark.mielke.cc
Cc: Donald Courtney <Donald.Courtney@Sun.COM>
Cc: William Yu <wyu@talisys.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Caching by Postgres
Date: Wed, 24 Aug 2005 14:47:09 -0400
Message-ID: <430CC0AD.5040400@rentec.com> (raw)
In-Reply-To: <20050824173055.GA11788@mark.mielke.cc>
References: <20050823171045.12112.qmail@web51309.mail.yahoo.com>
	<20050823124323.710a9dd3.frank@wiles.org>
	<430B6DE3.6040109@sun.com>
	<deg68k$16gh$1@news.hub.org>
	<430C7448.7030103@sun.com>
	<20050824173055.GA11788@mark.mielke.cc>

mark@mark.mielke.cc wrote:
> So then we move on to what 64-bit is really useful for. Obviously,
> there is the arithmetic. If you were previously doing 64-bit
> arithmetic through software, you will notice an immediate speed
> improvement when doing it through hardware instead. If you have
> a program that is scanning memory in any way, it may benefit from
> 64-bit instructions (for example - copying data 64-bit words at
> a time instead of 32-bit words at a time). PostgreSQL might benefit
> slightly from either of these, slightly balancing the performance
> degradation of using more memory to store the pointers, and more
> memory bandwidth the access the pointers.
>   
At least on Sparc processors, v8 and newer, any double precision math 
(including longs) is performed with a single instruction, just like for 
a 32 bit datum.  Loads and stores of 8 byte datums are also handled via 
a single instruction.   The urban myth that 64bit math is 
different/better on a 64 bit processor is just that;  yes, some lower 
end processors would emulate/trap those instructions but that an 
implementation detail, not architecture.    I believe that this is all 
true for other RISC processors as well.

The 64bit API on UltraSparcs does bring along some extra FP registers IIRC.

> If, however, you happen to have a very large amount of physical memory
> - more memory than is supported by a 32-bit system, but is supported
> by your 64-bit system, then the operating system should be able to use
> this additional physical memory to cache file system data pages, which
> will benefit PostgreSQL if used with tables that are larger than the
> memory supported by your 32-bit system, and which have queries which
> require more pages than the memory supported by your 32-bit system to
> be frequently accessed. If you have a huge database, with many clients
> accessing the data, this would be a definate yes. With anything less,
> it is a maybe, or a probably not.
>   
Solaris, at least, provided support for far more than 4GB of physical 
memory on 32 bit kernels.  A newer 64 bit kernel might be more 
efficient, but that's just because the time was taken to support large 
page sizes and more efficient data structures.  It's nothing intrinsic 
to a 32 vs 64 bit kernel.

-- Alan



view thread (31+ messages)  latest in thread

Message-ID: <430CC0AD.5040400@rentec.com>
Permalink:  ../430CC0AD.5040400@rentec.com/
Also on:    postgresql.org/message-id/430CC0AD.5040400@rentec.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: stange@rentec.com, mark@mark.mielke.cc, Donald.Courtney@Sun.COM, wyu@talisys.com
  Subject: Re: Caching by Postgres
  In-Reply-To: <430CC0AD.5040400@rentec.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox