From owner-freebsd-chat@FreeBSD.ORG Thu Oct 30 04:02:54 2003 Return-Path: Delivered-To: freebsd-chat@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5EE0616A4CE for ; Thu, 30 Oct 2003 04:02:54 -0800 (PST) Received: from heron.mail.pas.earthlink.net (heron.mail.pas.earthlink.net [207.217.120.189]) by mx1.FreeBSD.org (Postfix) with ESMTP id AA9D243FAF for ; Thu, 30 Oct 2003 04:02:53 -0800 (PST) (envelope-from tlambert2@mindspring.com) Received: from user-2ivfim6.dialup.mindspring.com ([165.247.202.198] helo=mindspring.com) by heron.mail.pas.earthlink.net with asmtp (SSLv3:RC4-MD5:128) (Exim 3.33 #1) id 1AFBVs-0000hh-00; Thu, 30 Oct 2003 04:02:52 -0800 Message-ID: <3FA0FDB2.4B4C56F8@mindspring.com> Date: Thu, 30 Oct 2003 04:01:54 -0800 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bill Moran References: <3FA00634.6000002@potentialtech.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-ELNK-Trace: b1a02af9316fbb217a47c185c03b154d40683398e744b8a4fb54558185c1f9affe2945bf4e2997de350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c cc: chat@freebsd.org Subject: Re: How much better are 64 but platforms X-BeenThere: freebsd-chat@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Non technical items related to the community List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Oct 2003 12:02:54 -0000 Bill Moran wrote: > I mean, if you just took FreeBSD (for example) by > itself and moved it from 32 - 64 bit, how much faster is it (assuming the same > mhz processor, if possible). How about PostgreSQL (which is the database > server we're using). If your application is swap/mmory bound, then putting it on a 64 bit box and installing a grundle of RAM would make it faster (grundle>4G). > In general, how much faster is C compiled on a 64 bit platform? Slower. Half as much data transferred per cycle for things that used to be 32 bit but are now 64 bit (think instruction/data prefetch). > Basically, all > this app does is pull a crapload of database records into RAM, do a whole bunch > of string comparisons, generate some percentages, and write significant results > back to another database table. Should I expect 64 bit to be a big improvement? String compares could be made significantly faster for runs of 8 or more bytes. See the copin/copyout/bcopy/etc. code for examples of doing things in as-large-chunks-as-you-can-at-a-time. Note that use of 64 bit registers on 32 bit machines means dirtying FPU registers, which makes context switches slower; using 64 bit registers for this instead saves on context switch overhead. You will likely need to hand-code and hand-optimize routines to take advantagoe of this. On Itanium, this will be rather difficult to get your head around, because the CPU is so strange. Also, I'll repeat what someone else said: use an AMD64 instead of an Itanium: the compiler generates better code. -- Terry