Browse Source

Return a somewhat sane default value for L2 cache size if cpuid returned something unexpected

Fixes #1610, the KVM hypervisor on Google Chromebooks returning zero for CPUID  0x80000006, causing DYNAMIC_ARCH
builds of OpenBLAS to hang
pull/1611/head
Martin Kroeker GitHub 8 years ago
parent
commit
6fa7e8ccd2
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      kernel/setparam-ref.c

+ 3
- 1
kernel/setparam-ref.c View File

@@ -647,7 +647,9 @@ static int get_l2_size_old(void){
return 6144;
}
}
return 0;
// return 0;
fprintf (stderr,"OpenBLAS WARNING - could not determine the L2 cache size on this system, assuming 256k\n");
return 256;
}
#endif



Loading…
Cancel
Save