Re: How to turn off hyperthreading?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, March 25, 2013 1:39 pm, Jostein Chr. Andersen wrote:
> On 03/25/2013 08:06 PM, david wrote:
>> The laptop I'm considering (Zareason Verix 530) as replacement for my
>> current one has a dual-core Intel i3 processor with hyperthreading.
>> Zareason says there's no way to turn off HT in BIOS.
>>
>> I think folk on the list have said that HT causes problems with RT. So
>> how can I disable hyperthreading?
>
> I can do like this in my Kubuntu system which have 8 kernels:
>
> sudo echo 0 > /sys/devices/system/node/node0/cpu0/online
> sudo echo 0 > /sys/devices/system/node/node0/cpu2/online

That should be all you need with two cores, turn off cpu 0 and 2, though
most people turn off 1 and 3 :)
> sudo echo 0 > /sys/devices/system/node/node0/cpu7/online

Which is why the cpu 7 here.

Linux sees the each core as two cpus, one for each thread. Not only might
a thread be using too much time but there is also the overhead of context
switching (invisible to the kernel) from one thread to the other. With
hyper threading on, I can run jack at 64 frames with few xruns. With
hyperthreading off, I can get down to 16 frames with guitarix running and
no xruns. (10 year old single core p4 at 2.4G) Read up on some of the cnc
projects where they require lower latency than audio. Lots of good info.

Hyperthreading improves "performance" over all, but raises the latency
audio can run at without dropouts. Once you hit 4 cores though,
hyperthreading is more of a gimmick than a help.

Every second thread/cpu can also be disabled on the kernel command line in
grub:

isolcpus= cpu_number[, cpu_number,...]

The cnc people also use this to hide a cpu away from the OS so they can
have full access to that cpu for just their application without the OS
using it too.


-- 
Len Ovens
www.OvenWerks.net

_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@xxxxxxxxxxxxxxxxxxxx
http://lists.linuxaudio.org/listinfo/linux-audio-user




[Index of Archives]     [Linux Sound]     [ALSA Users]     [Pulse Audio]     [ALSA Devel]     [Sox Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux