public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "J.A. Magallon" <jamagallon@able.es>
To: Dave Jones <davej@codemonkey.org.uk>
Cc: Margit Schubert-While <margitsw@t-online.de>,
	linux-kernel@vger.kernel.org
Subject: Re: 2.4.19/20, 2.5 missing P4 ifdef ?
Date: Fri, 29 Nov 2002 01:08:59 +0100	[thread overview]
Message-ID: <20021129000859.GA2027@werewolf.able.es> (raw)
In-Reply-To: <20021128142437.GA23664@suse.de>; from davej@codemonkey.org.uk on Thu, Nov 28, 2002 at 15:24:37 +0100


On 2002.11.28 Dave Jones wrote:
>On Thu, Nov 28, 2002 at 03:17:53PM +0100, Margit Schubert-While wrote:
> > Just noticed this in "include/asm-i386/processor.h" :
> > 
> > --- snip ---
> > /* Prefetch instructions for Pentium III and AMD Athlon */
> > #ifdef  CONFIG_MPENTIUMIII
> > #define ARCH_HAS_PREFETCH
> > extern inline void prefetch(const void *x)
> > {
> >         __asm__ __volatile__ ("prefetchnta (%0)" : : "r"(x));
> > }
> > #elif CONFIG_X86_USE_3DNOW
> > --- end snip ---
> > 
> > The P4 has SSE and prefetch or no ?
>
>It does. You seem to have found a bug.
>

Two questions:
- I am trying to use gcc's __builtin_prefetch, and it is able to
  spit different prefetch instructions depending on 'temporal
  locality' of the data:
	prefetchnta, prefetcht2, prefetcht1, prefetcht0
temp-loc:    0           1         2           3
  0 means you can just discard after r or w, and 3 means you
  are really interested in data lasting in cache.
  Do not know if the use of prefetch in kernel is extensive,
  but perhaps this is something to investigate...

- PII also supports the prefetches. Is it worth to add it ?

TIA

-- 
J.A. Magallon <jamagallon@able.es>      \                 Software is like sex:
werewolf.able.es                         \           It's better when it's free
Mandrake Linux release 9.1 (Cooker) for i586
Linux 2.4.20-rc4-jam0 (gcc 3.2 (Mandrake Linux 9.1 3.2-4mdk))

  parent reply	other threads:[~2002-11-29  0:01 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-28 14:17 2.4.19/20, 2.5 missing P4 ifdef ? Margit Schubert-While
2002-11-28 14:24 ` Dave Jones
2002-11-28 17:12   ` Bill Davidsen
2002-11-29  4:51     ` GrandMasterLee
2002-11-29  0:08   ` J.A. Magallon [this message]
2002-12-02 13:24     ` Dave Jones
  -- strict thread matches above, loose matches on Subject: below --
2002-11-29  7:42 Margit Schubert-While
2002-12-03  9:01 Margit Schubert-While

Reply instructions:

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

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

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021129000859.GA2027@werewolf.able.es \
    --to=jamagallon@able.es \
    --cc=davej@codemonkey.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=margitsw@t-online.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox