From: Ralf Baechle <ralf@linux-mips.org>
To: Greg Weeks <greg.weeks@timesys.com>
Cc: linux-mips@linux-mips.org
Subject: Re: memcpy prefetch
Date: Thu, 7 Apr 2005 13:25:04 +0100 [thread overview]
Message-ID: <20050407122504.GY4948@linux-mips.org> (raw)
In-Reply-To: <4255240E.4050701@timesys.com>
On Thu, Apr 07, 2005 at 08:14:06AM -0400, Greg Weeks wrote:
> What's the performance hit for doing a pref on a cache line that is
> already pref'd?
A wasted instruction.
(More complicated on certain multi-issue in-order processors such as the
SB1 CPU core. Mentioning this for completeness; we shouldn't worry about
it here.)
> Does it turn into a nop, or do we get some horrible
> degenerate case? Are 64 bit processors always at least 32 byte cache
> line size?
The smallest D-cache line I know of is 16 bytes.
> I don't really expect anyone to know the answers right now. I
> expect I'll need to time code to tell. This makes generating them at run
> time look better and better.
Indeed. Initially when we started doing such things some people felt it
might be really bad to debug and everything but in practice it's been a
relativly minor problem, so I guess the resistance against yet another
run-time generated group of functions is getting less.
One interesting issue to solve - memcpy, memmove and copy_user are combined
into a single big function, so the fixups for userspace accesses need to
be handled at runtime as well.
Ralf
next prev parent reply other threads:[~2005-04-07 12:25 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-06 12:30 memcpy prefetch Greg Weeks
2005-04-06 20:08 ` Ralf Baechle
2005-04-07 12:14 ` Greg Weeks
2005-04-07 12:25 ` Ralf Baechle [this message]
2005-04-07 12:25 ` Michael Uhler
2005-04-07 12:25 ` Michael Uhler
2005-04-07 12:28 ` Dominic Sweetman
2005-04-07 14:05 ` Ralf Baechle
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=20050407122504.GY4948@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=greg.weeks@timesys.com \
--cc=linux-mips@linux-mips.org \
/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