Date: Fri, 9 Mar 2012 16:30:05 -0500 (EST) From: Garrett Wollman <wollman@csail.mit.edu> To: FreeBSD-gnats-submit@FreeBSD.org Subject: kern/165893: processor topology should be exported in more obvious format Message-ID: <201203092130.q29LU52n043520@zfsnfs.csail.mit.edu> Resent-Message-ID: <201203092140.q29Le6FM047597@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 165893 >Category: kern >Synopsis: processor topology should be exported in more obvious format >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Fri Mar 09 21:40:06 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Garrett Wollman >Release: FreeBSD 9.0-RELEASE amd64 >Organization: MIT Computer Science & Artificial Intelligence Lab >Environment: System: FreeBSD zfsnfs.csail.mit.edu 9.0-RELEASE FreeBSD 9.0-RELEASE #3 r232145M: Sun Feb 26 20:00:10 EST 2012 wollman@zfsnfs.csail.mit.edu:/usr/obj/usr/src/sys/ZFSNFS amd64 >Description: Currently, the sysctl variable hw.ncpu gives the number of logical processors. kern.sched.topology_spec gives a hard-to-parse XML description of the system topology (is this ULE-only or 4BSD as well?). Grepping /var/run/dmesg.boot will tell you the number of sockets, cores, and threads without having to parse XML. It would be preferable if these values were reflected in sysctl variables (in, take your pick, the kern.sched, hw, machdep, or dev.cpu tree) so programs don't have to parse XML or depend on being able to read dmesg.boot. >How-To-Repeat: >Fix: Sprinkle some SYSCTL_RDINT() macros into ${ARCH}/mp_machdep.c. >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201203092130.q29LU52n043520>