Messages in this thread | | | Subject | Re: [PATCH] Remove implicit list prefetches for most cases | From | Paul Moore <> | Date | Wed, 08 Sep 2010 08:32:59 -0400 |
| |
On Wed, 2010-09-08 at 10:59 +0200, Andi Kleen wrote: > From: Andi Kleen <ak@linux.intel.com> > > We've had explicit list prefetches in list_for_each and friends > for quite some time. According to Arjan they were originally > added for K7 where they were a slight win. > > It's doubtful they help very much today, especially on newer CPUs with > aggressive prefetching. Most list_for_eachs bodies are quite short and > the prefetch does not help if it doesn't happen sufficiently in advance > or when the data is not really cache cold. > > The feedback from CPU designers is that they don't like us using explicit > prefetches unless there is a very good reason (and list_for_each* alone > clearly isn't one) > > Also the prefetches cause the list walks to generate bad code, > increase the number of registers needed.
If prefetch() is generally considered a "Bad Thing", I'm OK with just removing them from NetLabel; no need to rename and conditionalize. I put them in the netlbl_af[4,6]list_*() routines because those routines were modeled after the normal list routines which had prefetches and I just assumed someone much smarter had found them to be a win.
-- paul moore linux @ hp
| |