Package org.wildfly.common.cpu
Class CacheLevelInfo
java.lang.Object
org.wildfly.common.cpu.CacheLevelInfo
- Author:
- David M. Lloyd
-
Method Summary
Modifier and TypeMethodDescriptionintGet the level index.intGet the size of this cache level in kilobytes.intGet the cache line size in bytes.Get the type of cache.
-
Method Details
-
getCacheLevel
public int getCacheLevel()Get the level index. For example, the level of L1 cache will be "1", L2 will be "2", etc. If the level is not known, 0 is returned.- Returns:
- the level index, or 0 if unknown
-
getCacheType
Get the type of cache. If the type is unknown,CacheType.UNKNOWNis returned.- Returns:
- the type of cache (not
null)
-
getCacheLevelSizeKB
public int getCacheLevelSizeKB()Get the size of this cache level in kilobytes. If the size is unknown, 0 is returned.- Returns:
- the size of this cache level in kilobytes, or 0 if unknown
-
getCacheLineSize
public int getCacheLineSize()Get the cache line size in bytes. If the size is unknown, 0 is returned.- Returns:
- the cache line size in bytes, or 0 if unknown
-