From owner-freebsd-current@FreeBSD.ORG Fri Jan 25 03:26:23 2008 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B7E1716A417 for ; Fri, 25 Jan 2008 03:26:23 +0000 (UTC) (envelope-from bruce@zuhause.org) Received: from mail.zuhause.org (216.243.156.193.real-time.com [216.243.156.193]) by mx1.freebsd.org (Postfix) with ESMTP id 1FA0E13C43E for ; Fri, 25 Jan 2008 03:26:23 +0000 (UTC) (envelope-from bruce@zuhause.org) Received: from bhfs.zuhause.org (bhfs.zuhause.org [10.0.2.10]) by mail.zuhause.org (Postfix) with ESMTP id 3DA567C04 for ; Thu, 24 Jan 2008 21:26:22 -0600 (CST) Received: by bhfs.zuhause.org (Postfix, from userid 1001) id 45A4B5C023; Thu, 24 Jan 2008 21:26:54 -0600 (CST) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18329.22270.123314.900543@bhfs.zuhause.org> Date: Thu, 24 Jan 2008 21:26:54 -0600 To: freebsd-current@freebsd.org From: bruce@zuhause.mn.org In-Reply-To: References: <18328.45282.562906.708945@celery.zuhause.org> X-Mailer: VM 7.17 under 21.4 (patch 20) "Double Solitaire" XEmacs Lucid Subject: Re: Weird performance behaviour in 7.0 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2008 03:26:23 -0000 Richard Todd writes: > Bruce Albrecht writes: > > > This is my first Q6600 based system, and my first 7.0 system, and my > > first AMD-64 system and my first ZFS base system, and I'm seeing > > something really strange. Every now and then, processes run really > > slowly, like at 1/600th (or worse) than it ought to, but it racks up > > the CPU time as though it's running full tilt. > > > > For example, I have this little test program that just does a tight > > loop, and most times, it takes about 3 seconds to complete, but right > > now, it's taking about 2000 seconds to complete. Right now, it's > > consistently running slow, but sometimes it will run slow, but I can > > terminate it and start another one which will run at normal speed. > > This wouldn't by any chance be an Intel 965-chipset-based motherboard > with 4G or more of memory, would it? Because there's an interesting > little bug in the BIOS on some of those boards which causes the > cache-control registers to incorrectly declare a chunk of main memory > as uncacheable. This results in random slowdowns depending on whether > your process lands in the "bad" zone of memory or not. See > http://article.gmane.org/gmane.os.freebsd.stable/50135/ for more details. Bingo! This is a Intel DG965WH with 4 GB of memory. I don't think I can downgrade to the 1669 firmware because of the processor I'm using. The Fedora thread says that there's a hack to do the following in linux to fix the "bad" zone echo "base=0x1a8000000 size=0x4000000 type=write-back" >| /proc/mtrr What would be the FreeBSD equivalent? The output of memcontrol list is 0x0/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x10000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x20000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x30000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x40000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x50000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x60000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x70000/0x10000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x80000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x84000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x88000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x8c000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x90000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x94000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x98000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0x9c000/0x4000 BIOS write-back fixed-base fixed-length set-by-firmware active 0xa0000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xa4000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xa8000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xac000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xb0000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xb4000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xb8000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xbc000/0x4000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc0000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc1000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc2000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc3000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc4000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc5000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc6000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc7000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc8000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xc9000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xca000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xcb000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xcc000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xcd000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xce000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xcf000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd0000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd1000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd2000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd3000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd4000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd5000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd6000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd7000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd8000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xd9000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xda000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xdb000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xdc000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xdd000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xde000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xdf000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe0000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe1000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe2000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe3000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe4000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe5000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe6000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe7000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe8000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xe9000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xea000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xeb000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xec000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xed000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xee000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xef000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf0000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf1000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf2000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf3000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf4000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf5000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf6000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf7000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf8000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xf9000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xfa000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xfb000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xfc000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xfd000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xfe000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0xff000/0x1000 BIOS uncacheable fixed-base fixed-length set-by-firmware active 0x0/0xf080000000 BIOS write-back set-by-firmware active bogus 0x80000000/0xf040000000 BIOS write-back set-by-firmware active bogus 0xc0000000/0xf010000000 BIOS write-back set-by-firmware active bogus 0xcf800000/0xf000800000 BIOS uncacheable set-by-firmware active bogus 0xcf700000/0xf000100000 BIOS uncacheable set-by-firmware active bogus