turn off hyperthreading when i'am using Matlab

20 ビュー (過去 30 日間)
Othman
Othman 2011 年 2 月 23 日
コメント済み: Mohammad Sayyafzadeh 2015 年 11 月 12 日
Hi,
I would like to turn off the hyper threading when i'm using Matlab in on a computer with the following configuration:
MATLAB: R2010b,
OS: Mac pro,
CPU: Intel Xeon (2 processors),
RAM: 8 GB,
ATI Radeon HD 5870
Any help please, thank you in advance

回答 (2 件)

Sarah Wait Zaranek
Sarah Wait Zaranek 2011 年 3 月 6 日
Depending on your release, you can either turn it off in the preferences - or for newer releases there is a start up option for turning it off. It is -singleCompThread.
If you are using an older version (and want to toggle while running), you can use the maxNumCompThreads command (available in R2007b through R2010a). Loren has a nice blog post about this, see link below.
  1 件のコメント
Sarah Wait Zaranek
Sarah Wait Zaranek 2011 年 3 月 6 日
Just noticed you are in 10b. The startup option is the way to go for you.

サインインしてコメントする。


Walter Roberson
Walter Roberson 2011 年 3 月 6 日
編集済み: Jan 2013 年 1 月 18 日
Sarah's answer is good if you want to turn off all threading. If you want to turn off only hyperthreading, here is some information from 2009; I don't know if it has become a regular preference in the meantime.
  2 件のコメント
Sarah Wait Zaranek
Sarah Wait Zaranek 2011 年 3 月 6 日
Good Point.
MATLAB looks to the OS to see how many cores the machine has - and uses that to set the number of computational threads. For machines with hyperthreading, the OS doesn't distinguish between real core and "virtual" ones. So, this means if you want hyperthreading off you have two options
1) Turn of all multithreading in MATLAB
2) Turn off hyperthreading on the OS level - then MATLAB will remain multithreaded but use the real cores to set the number of computational threads.
Mohammad Sayyafzadeh
Mohammad Sayyafzadeh 2015 年 11 月 12 日
I have a similar issue. The computer has 4 16-core CPUs. 64 physical CPUs, no hyper-threads. But MatLab recognises half of them as hyperthreads and therefore, it uses only 32 cores. Anyone knows why is that and how I can resolve this issue? feature('numCores') MATLAB detected: 32 physical cores. MATLAB detected: 64 logical cores. MATLAB was assigned: 64 logical cores by the OS. MATLAB is using: 32 logical cores. MATLAB is not using all logical cores because hyper-threading is enabled.
ans =
32

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeJava Package Integration についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by