From owner-freebsd-hackers Thu Sep 10 22:12:49 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id WAA09041 for freebsd-hackers-outgoing; Thu, 10 Sep 1998 22:12:49 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from allegro.lemis.com (allegro.lemis.com [192.109.197.134]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id WAA09036 for ; Thu, 10 Sep 1998 22:12:44 -0700 (PDT) (envelope-from grog@freebie.lemis.com) Received: from freebie.lemis.com (freebie.lemis.com [192.109.197.137]) by allegro.lemis.com (8.9.1/8.9.0) with ESMTP id OAA00753; Fri, 11 Sep 1998 14:42:23 +0930 (CST) Received: (from grog@localhost) by freebie.lemis.com (8.9.1/8.9.0) id OAA07470; Fri, 11 Sep 1998 14:42:22 +0930 (CST) Message-ID: <19980911144222.N611@freebie.lemis.com> Date: Fri, 11 Sep 1998 14:42:22 +0930 From: Greg Lehey To: Kelly Yancey , freebsd-hackers@FreeBSD.ORG Subject: Re: New AMD processor support patch References: <35F8A20E.7257F30E@freedomnet.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.91.1i In-Reply-To: <35F8A20E.7257F30E@freedomnet.com>; from Kelly Yancey on Fri, Sep 11, 1998 at 12:07:42AM -0400 WWW-Home-Page: http://www.lemis.com/~grog Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-41-739-7062 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Friday, 11 September 1998 at 0:07:42 -0400, Kelly Yancey wrote: > Hi all, > > Apparently I made a little faux-pa (sorry, I don't actually know > french :) ) faux pas ("false pace" or wrong step). > back in April or so...I submitted a patch to add proper detection of > the AMD CPU and the ability to enable the write allocate feature > found on K5 and K6 CPUs. It just recently came to my attention that > I uploaded the wrong patch :( It looked pretty relevant to me. > The only reason I even noticed is that I mentioned to a friend of > mine , John, that on the 1 system in my office that the feature > worked on that it sped things up by about 10-15%. Next thing I know, > I notice several people on this list are stating that the feature > works seems to work on their system but that they aren't seeing any > performance gain. Yes, I was one of them. I also had a good reason for the discrepancy: if this feature would always be an improvement, it wouldn't need to be an option. > That is when it occurred to me that perhaps I didn't upload the correct > patch (another version ANDed when it should have ORed and never actually > turned on write allocate). > So, to make a long story short, here is the correct patch (I updated > it to detect the new K6-2 processors too): > http://www.posi.net/software/public/freebsd/AMD_WT_ALLOC.patch > > To enable write allocate support, add the following line to your > kernel config (after applying the patches of course :) ): > > options CPU_AMD_WT_ALLOC > > Now, for the tricky part: write allocate does not work on all systems. > AMD's K6 FAQ states: > " The write allocate utility is intended for development use only. > Write allocate feature is supported for AMD-K6 processor in the > following BIOS revisions: > > Award - Compile dates of March 1, 1997 or later > AMI - CPU Module 3.31 or later > Phoenix - Version 4.0 > Release 6.0 or Release 5.1 w/build dates 4/7/97 or later. > " BIOSes are an idea in the mind of Microsoft. We don't use them after booting. > On my systems that do not work with write allocate I typically get > messages from ahc0 complaining about RAM parity errors. So be prepared > to fallback onto your kernel.old Strange. You'd expect it to have no effect at all. > Anyway, just in case your interested in why write allocate gives such > great performance increases (when it works), AMD describes its function > in their write allocate application note at: > http://www.amd.com/K6/k6docs/pdf/21326d.pdf Yes, I read that. > If there is any interest I would like to add a cpu feature check for > the AMD 3DNow! instructions. I'm sure that would be of interest, though it doesn't affect my processor. I'm off to a conference for a week, but when I get back I'll try out the patches (assuming nobody beats me to it) and report the results. Greg -- See complete headers for address, home page and phone numbers finger grog@lemis.com for PGP public key To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message