Re: return the "Processor ID"
- From: "Ken" <sparkzz@xxxxxxx>
- Date: 24 Feb 2006 18:40:50 -0800
Josef Moellers wrote:
Roger Leigh wrote:
greg.yang@xxxxxxxxx writes:
I want to ask which function/system call can return the ID of the
processor that current thread is running on.
Is this a useful question to ask? Your process could be scheduled at
any moment on any CPU, so the answer is not going to be meaningful,
since it could be wrong as soon as you get it.
It could even change _while_ you're getting it:
CPU0: running application
CPU0: int 0x80 (GetCPUID)
CPU0: getting "0", about to return to user mode
CPU0: hit by interrupt, forcing current process to reschedule
CPU1: resuming GetCPUID into user mode
CPU1: running application
--
Josef Möllers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize
-- T. Pratchett
.
- Follow-Ups:
- Re: return the "Processor ID"
- From: Josef Moellers
- Re: return the "Processor ID"
- References:
- return the "Processor ID"
- From: greg . yang
- Re: return the "Processor ID"
- From: Roger Leigh
- Re: return the "Processor ID"
- From: Josef Moellers
- return the "Processor ID"
- Prev by Date: Re: Trolltech QT license question
- Next by Date: Re: Will GCC-6.0 Warn On Spelling Mistakes In Comments And Function Names?
- Previous by thread: Re: return the "Processor ID"
- Next by thread: Re: return the "Processor ID"
- Index(es):
Relevant Pages
|