Cygwin: cpuinfo: report L3 cache on Intel CPUs

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen 2018-04-11 10:06:25 +02:00
parent 8a91646183
commit 402d68af1a
1 changed files with 3 additions and 2 deletions

View File

@ -768,8 +768,9 @@ format_proc_cpuinfo (void *, char *&destbuf)
extern long get_cpu_cache_intel (int sysc, uint32_t maxf);
long cs;
/* As on Linux, don't check for L3 cache. */
cs = get_cpu_cache_intel (_SC_LEVEL2_CACHE_SIZE, maxf);
cs = get_cpu_cache_intel (_SC_LEVEL3_CACHE_SIZE, maxf);
if (cs == -1)
cs = get_cpu_cache_intel (_SC_LEVEL2_CACHE_SIZE, maxf);
if (cs == -1)
{
cs = get_cpu_cache_intel (_SC_LEVEL1_ICACHE_SIZE, maxf);