• Welcome to Valhalla Legends Archive.
 

Finding cache size

Started by Arta, January 25, 2004, 10:18 AM

Previous topic - Next topic

Arta

Does anyone know of a way (functional under >=win2k)  to find the size of the processor's L2 cache?

Skywing

You can use cpuid with level=2 to get it from P4s...

Arta

Quote from: Skywing on January 25, 2004, 10:39 AM
You can use cpuid with level=2 to get it from P4s...

Would rather use a non-cpuspecific way if there is one.

Adron

You could make a loop doing an operation on a dataset of a certain size. Increase size step by step and measure performance. When performance drops more than linearly, you've hit the cache size.