6

In the past few years, looking at Intel CPUs, there has been a move from large size L2 cache to large size L3 cache. A lot of this is due to having more cores on the CPU and wanting to share the cache between them (an L3 advantage).

But supposing I have a single threaded application and I want to compare the speed I get running it on 2 different CPUS that share the same clock speed :

  1. a CPU with 6MB L2 cache @3.1Ghz (e.g., Core 2 Duo E8500)

  2. a CPU with 6MB L3 cache @3.1Ghz (e.g., Core i5 2400)

Disregarding turbo boost effects and faster DDR factors, It seems the first (older) CPU should perform much faster (as it is closer to the core level), no ?

Another question that interests me, In old times, back in the first days of L2 cache in CPUs I seem to recall that L2 cache is accessed at half the CPU clock speed, is that still true today ? and what about L3 speed ?

1
  • AFAIK, L2/L3 is accessed at clock speed. As for the first question - there's no way to answer it.
    – Sathyajith Bhat
    Jan 25, 2011 at 14:17

3 Answers 3

5

It depends. If the inner loop of your program fits into the L1 cache of both CPUs and memory speeds are the same, you won't see much difference.

If the inner loop fits into the 6MB L2 cache, but does not fit into the L2 cache of the CPU with 6MB L3 cache, then the program will be faster on the older CPU with the larger L2 cache.

But in general, the inner loop part of a program is very small.

1
  • thanks for the answer... I guessed as much... but the speed issue still is not known to me ... at what speeds do each cache level run at
    – thedrs
    Feb 9, 2011 at 13:35
2

Intel uses a new cache technology called "Smart Cache" so I doubt any comparisons between current models now and CPUs from years ago are on a level playing field. Keep in mind that I think "Smart Cache" is an Intel technology only; AMD uses something called "Balanced Smart Cache".

Wikipedia info:

Smart Cache is a level 2 or level 3 cache method for multiple execution cores invented by Intel. It shares the cache among cores (CPU Core or GPU). In comparison to a dedicated cache per core the overall cache miss rate decreases in times where not all cores need equally much cache space. Consequently a single core can use the full level 2 cache or level 3 cache, if the other cores are inactive. Furthermore the shared cache makes it faster to share memory among different execution cores.

0

Concerning the second part of the question, yes it's still true to some degree. L1 is faster than L2, and L3 is slower than L2. But I would not it call it "half frequency" since CPU design varies greatly.

Also I guess Core i5 will be faster almost always, because cache size is important, but also important is cache speed and miss rate, as well as overall CPU design.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .