From: James Cleverdon <jamesclv@us.ibm.com>
To: John Bradford <john@grabjohn.com>
Cc: lunz@falooley.org, linux-kernel@vger.kernel.org
Subject: Re: detecting hyperthreading in linux 2.4.19
Date: Thu, 9 Jan 2003 16:16:14 -0800 [thread overview]
Message-ID: <200301091616.14195.jamesclv@us.ibm.com> (raw)
In-Reply-To: <200301092154.h09Ls5SX005123@darkstar.example.net>
On Thursday 09 January 2003 01:54 pm, John Bradford wrote:
> > > Is there a way for a userspace program running on linux 2.4.19 to tell
> > > the difference between a single hyperthreaded xeon P4 with HT enabled
> > > and a dual hyperthreaded xeon P4 with HT disabled? The /proc/cpuinfos
> > > for the two cases are indistinguishable.
> >
> > I don't know of any way to do this in userland. The whole point is that
> > the sibling processors are supposed to look like real ones.
> >
> > You _could_ try running two processes simultaneously in tight spin loops
> > for 100 million cycles and comparing the amount of real time consumed.
> > That would be rather unreliable and kludgey though.
>
> If /proc/interrupts shows a processor is handling interrupts then it
> is definitely a 'real' one. If it isn't handling interrupts, it may
> or may not be a 'real' one. That's another unreliable and kludgey way
> to tell the difference :-).
>
> John.
> -
Not quite. The "logical" or "sibling" processor has its own local APIC. This
is necessary to send it the Startup IPI and soft IPIs while the system is
running.
However, it is a full function APIC and can receive I/O interrupts. I have
seen this happen many times.
--
James Cleverdon
IBM xSeries Linux Solutions
{jamesclv(Unix, preferred), cleverdj(Notes)} at us dot ibm dot com
next prev parent reply other threads:[~2003-01-10 0:08 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-09 20:02 detecting hyperthreading in linux 2.4.19 Jason Lunz
2003-01-09 21:37 ` James Cleverdon
2003-01-09 21:54 ` John Bradford
2003-01-10 0:16 ` James Cleverdon [this message]
2003-01-10 0:58 ` Mike Dresser
2003-01-09 21:57 ` Jason Lunz
2003-01-10 12:29 ` Mark Hounschell
2003-01-10 7:05 ` Mikael Pettersson
2003-01-10 11:05 ` Dave Jones
2003-01-10 11:19 ` Mikael Pettersson
2003-01-10 0:20 ` Dave Jones
-- strict thread matches above, loose matches on Subject: below --
2003-01-09 22:29 Kamble, Nitin A
2003-01-09 23:26 Pallipadi, Venkatesh
2003-01-10 8:16 Pallipadi, Venkatesh
2003-01-10 8:43 ` Mikael Pettersson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200301091616.14195.jamesclv@us.ibm.com \
--to=jamesclv@us.ibm.com \
--cc=john@grabjohn.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lunz@falooley.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.