diff options
author | Brian Inglis <Brian.Inglis@SystematicSW.ab.ca> | 2019-10-07 10:23:02 -0600 |
---|---|---|
committer | Ken Brown <kbrown@cornell.edu> | 2019-10-07 15:50:33 -0400 |
commit | 9682c25bb32df1428e4469b457034e87f199a3c8 (patch) | |
tree | 3a87e8984476d4bc50c9191f39eb15eccfe138ed | |
parent | 70e834ea7c970dd9bf98167e0cf7d4d7c643a225 (diff) | |
download | cygnal-9682c25bb32df1428e4469b457034e87f199a3c8.tar.gz cygnal-9682c25bb32df1428e4469b457034e87f199a3c8.tar.bz2 cygnal-9682c25bb32df1428e4469b457034e87f199a3c8.zip |
fhandler_proc.cc(format_proc_cpuinfo): add bogomips
Add bogomips which has been cpu MHz*2 since Pentium MMX.
-rw-r--r-- | winsup/cygwin/fhandler_proc.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/winsup/cygwin/fhandler_proc.cc b/winsup/cygwin/fhandler_proc.cc index 86c1f6253..8c290d2ff 100644 --- a/winsup/cygwin/fhandler_proc.cc +++ b/winsup/cygwin/fhandler_proc.cc @@ -696,6 +696,7 @@ format_proc_cpuinfo (void *, char *&destbuf) RtlQueryRegistryValues (RTL_REGISTRY_ABSOLUTE, cpu_key, tab, NULL, NULL); cpu_mhz = ((cpu_mhz - 1) / 10 + 1) * 10; /* round up to multiple of 10 */ + DWORD bogomips = cpu_mhz * 2; /* bogomips is double cpu MHz since MMX */ bufptr += __small_sprintf (bufptr, "processor\t: %d\n", cpu_number); uint32_t maxf, vendor_id[4], unused; @@ -1228,7 +1229,8 @@ format_proc_cpuinfo (void *, char *&destbuf) print ("\n"); - /* TODO: bogomips */ + bufptr += __small_sprintf (bufptr, "bogomips\t: %d.00\n", + bogomips); bufptr += __small_sprintf (bufptr, "clflush size\t: %d\n" "cache_alignment\t: %d\n", |