views:

40

answers:

2

Hi,
I was curious as to how is cache performance measured. Can you do it programmatically or do you need specialized tools for this purpose? Does the programming language being used matter?

Thanks,
Abhinav.

+1  A: 

The ratio of 'Cache Hits' versus 'Cache Misses' is the usual indicator of cache performance.

In the Windows/.NET world these would usually be measured by creating custom performance counters.

Mitch Wheat
Are there any resources how to do that? Can I do this from my Java code or does it have to be written in C or something else?
abhinav
I don't have any java specific information, I'm afraid.
Mitch Wheat
A: 

I will assume that you are on Windoze, because all such stats, and related stats are available in utilities that part of the operating system.

When you are using an app such as Windead, which is not an o/s (except in the marketing brochures), the easiest (labour wise) thing to do is, implement a Unix layer on top of it. There are many, such as Cygwin. That provides the o/s layer, and most of what can be expected from an o/s. Such as Virtual Memory Statistics. Nohing to write, it is just a single-line command. Google for vmstat.

PerformanceDBA