Welcome, Guest. Please login or register.

Author Topic: How L1 and L2 caches work  (Read 3925 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline biggun

  • Sr. Member
  • ****
  • Join Date: Apr 2006
  • Posts: 397
    • Show only replies by biggun
    • http://www.greyhound-data.com/gunnar/
Re: How L1 and L2 caches work
« Reply #14 from previous page: September 13, 2014, 03:59:33 PM »
Edit: in the above examples I mentioned 20 cyles latency for 2nd Level cache
and in the performance calculations we used 10 cycle.

This is no error - but this was under the realistic assumption that the compiler can work around the latency sometimes a little, That a pipeline design can sometimes help and that Prefething or Out Of order can soften the penalty sometimes.

Offline psxphill

Re: How L1 and L2 caches work
« Reply #15 on: September 13, 2014, 04:19:36 PM »
Quote from: A6000;772923
@Biggun, sorry, I don't understand this,

An L1 cache is fast because it is small, make it bigger and it slows down, so they add an L2 cache, but an L2 cache is slower than an L1.
I do not understand why an L1+L2 is faster than a larger L1 cache.

Imagine you are looking for a nail in your garage and it's really untidy. You decide that you'll keep some nails in your toolbox that you keep by the door, but you can't fit them all in. As soon as you run out of nails in your toolbox you have to go back to finding them in your garage. Having a toolbox that is as large as your garage wouldn't help as you'll fill it with all type of crap again and it will take just as long to find it.
 
 
Quote from: biggun;772886
Even money an not change the law of physiscs.
And physics simply dictates that increased size needs more space.
More space means longer wires, Longer wires means longer lantency.
Its very simply physics - which everybody will understand.

They've hit hard limits before that were said to be impossible to break, until they were.
 I'm sure one day it will be cost effective to increase L1 cache, some funky 3d circuits or using light instead of electricity etc.
« Last Edit: September 13, 2014, 04:28:43 PM by psxphill »
 

Offline A6000

  • Sr. Member
  • ****
  • Join Date: Nov 2007
  • Posts: 443
    • Show only replies by A6000
Re: How L1 and L2 caches work
« Reply #16 on: September 13, 2014, 04:29:49 PM »
OK, Thanks for the replies.