VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
jra at baylink.com Guest
|
Posted: Mon Apr 28, 2008 11:21 am Post subject: [asterisk-users] Hyperthreading and multicore |
|
|
On Sat, Apr 26, 2008 at 11:15:42AM +1000, Rob Hillis wrote:
Quote: | Two dual core processors would should four processors - each processor has
two virtual processors for a total of four.
|
I *think* Rob wrote that; *please*, people, turn your HTML off on
mailing lists?
Two dual-cores don't have *any* "virtual" processors; all four cores
are real.
The processors that are "virtual" are the ones on HT Pentiums.
Cheers,
-- jra
--
Jay R. Ashworth Baylink jra at baylink.com
Designer The Things I Think RFC 2100
Ashworth & Associates http://baylink.pitas.com '87 e24
St Petersburg FL USA http://photo.imageinc.us +1 727 647 1274
Those who cast the vote decide nothing.
Those who count the vote decide everything.
-- (Joseph Stalin) |
|
Back to top |
|
|
astmattf at gmail.com Guest
|
Posted: Mon Apr 28, 2008 3:02 pm Post subject: [asterisk-users] Hyperthreading and multicore |
|
|
On 4/28/08, Jay R. Ashworth <jra at baylink.com> wrote:
Quote: | On Sat, Apr 26, 2008 at 11:15:42AM +1000, Rob Hillis wrote:
Quote: | Two dual core processors would should four processors - each processor has
two virtual processors for a total of four.
|
I *think* Rob wrote that; *please*, people, turn your HTML off on
mailing lists?
Two dual-cores don't have *any* "virtual" processors; all four cores
are real.
The processors that are "virtual" are the ones on HT Pentiums.
Cheers,
-- jra
|
Multi-core processors on the Intel side are typically much faster and
run cooler than P4/Xeon Hyperthreading processors.
Also, I have heard HT processors explained this way, on an HT
processor it's like running 2 virtual processors at 70% of the specs
of the processor with HT turned off. It's not really like that in all
situations, but overall it has held pretty much true for me in most
non-Asterisk situations. Asterisk didn't benefit much from having HT
enabled on a P4 with HT capability.
MATT--- |
|
Back to top |
|
|
skoroneos at digital-o... Guest
|
Posted: Tue Apr 29, 2008 4:08 am Post subject: [asterisk-users] Hyperthreading and multicore |
|
|
Quote: | Asterisk didn't benefit much from having HT enabled on a P4
with HT capability.
|
There are several things that make a difference when optimizing for a
specific processor in order to take advantage of its features.
Gcc version used to build asterisk (and the system in general) and compile
flags can make a big difference
A lot of the "ready made" solutions use very generic optimization as they
are trying to be compatible with a wide range of cpu core's and
architectures.
This has the advantage of having a single binary image to distribute but you
pay for it in terms of performance.
In most cases the performance penalty is not noticable in small/home
installations but you start to notice it when you push the system to its
"resource" limit
(i.e cpu, memory,pci bus access etc) either because you handle a lot of
calls or your system is "resourse limited" i.e embedded boards.
So in general if you need to get the maximum performance out of a system,
make sure you build asterisk tuned for that system and not a "generic"
build.
Running code with 486 instruction set, with command scheduling for pentium
its not going to give you max performance regardless of the fact that your
cpu/core supports HT or not.
Stelios S. Koroneos
Digital OPSiS - Embedded Intelligence
http://www.digital-opsis.com |
|
Back to top |
|
|
rob at hillis.dyndns.org Guest
|
Posted: Tue Apr 29, 2008 8:55 am Post subject: [asterisk-users] Hyperthreading and multicore |
|
|
Matt Florell wrote:
Quote: | Also, I have heard HT processors explained this way, on an HT
processor it's like running 2 virtual processors at 70% of the specs
of the processor with HT turned off. It's not really like that in all
situations, but overall it has held pretty much true for me in most
non-Asterisk situations. Asterisk didn't benefit much from having HT
enabled on a P4 with HT capability.
|
That wouldn't surprise me - after all, HyperThreading works on the
principle of allowing two "threads" to use different dedicated processor
resources (such as floating point math processors and so on) at the same
time... however if two threads are trying to use the same processor
resource, one thread will be "suspended" until that resource becomes
available. |
|
Back to top |
|
|
mwatson at becon.org Guest
|
Posted: Tue Apr 29, 2008 9:35 am Post subject: [asterisk-users] Hyperthreading and multicore |
|
|
This is my understanding of hyper threading, which I believe to be accurate.
Basically, as some have mentioned previously, the OS 'sees' your single physical core processor as 2 logical processors, in generally, logical processors are treated exactly as if they were real processors, and in the case of many OS's. they probably don't understand the difference - Linux however does have specific SMT support for hyperthreaded cores.
Basically not all CPU instructions take the same amount of clock cycles to complete, some may take 3, some may take 7, etc.
Many of these clock cycles actually goto waste because the CPU is waiting for something, for example, an instruction that involves a fetch from memory, if this takes 7 clock cycles to complete, 4 of those cycles might go wasted while the CPU essentially just sits there and waits for the data to be fetched form RAM, L1 or L2, or L3 cache.
Hyperthreading essentially puts these wasted CPU cycles to use by allowing the CPU to execute a separate thread while it would otherwise be idle waiting.
To me Hyperthreading is an excellent technology... I;m all about efficiency and trying to maximize resource usage whenever possible... and that exactly what hyper threading does.
That all being said... Hyper threading should not be thought of as effectively doubling your CPU power... as previous posters have said, Hyper threading will result in single threaded applications actually running slower.. this is because you still have other background processes running which may run on the other logical processor which could steal CPU cycles away from your main application... since you essentially have 2 threads executing on the same physical core, there are going to be times when one thread has to wait extra clock cycles while the other thread is executing. Remember its only those normally "wasted" clock cycles that you are going to gain a performance boost out of by making use of them... only 1 thread can actually be executing at any given time, so the CPU has to schedule these and try balance the threads equally so they each get an equal share of the physical core.
I can't say how Asterisk behaves or makes use of additional cores or if hyper threading is advantageous to Asterisk or not... I don't know enough about the low level parts of Asterisk enough to make an informed opinion about that.
I just thought I'd throw in my 2 cents about what hyper threading is and what it does.
--
Matt
-----Original Message-----
From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Rob Hillis
Sent: Tuesday, April 29, 2008 9:56 AM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Hyperthreading and multicore
Matt Florell wrote:
Quote: | Also, I have heard HT processors explained this way, on an HT
processor it's like running 2 virtual processors at 70% of the specs
of the processor with HT turned off. It's not really like that in all
situations, but overall it has held pretty much true for me in most
non-Asterisk situations. Asterisk didn't benefit much from having HT
enabled on a P4 with HT capability.
|
That wouldn't surprise me - after all, HyperThreading works on the
principle of allowing two "threads" to use different dedicated processor
resources (such as floating point math processors and so on) at the same
time... however if two threads are trying to use the same processor
resource, one thread will be "suspended" until that resource becomes
available.
_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users |
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|