Matlab R2013a spend nearly 100% in one of four CPUs, how to fix it?

1 回表示 (過去 30 日間)
She
She 2016 年 4 月 5 日
編集済み: She 2016 年 4 月 5 日
When I debug an *.m file (about 300.0 kb) with several breakpoints, about 1.1 GB memory will be used.
And what's comfused me is the high CPU usage, nearly 100% for one of the four CPUs.
I tried several times but cannot fix it.
Ask for help. Thanks!
The following are the System information, CPUinfo, memory information, and Matlab version.
---------------------------- system information -------------------------
#uname -a
Linux She 2.6.32-573.el6.x86_64 #1 SMP Thu Jul 23 15:44:03 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
---------------------------- CPUinfo -------------------------
# dmidecode | grep -A81 'Processor Information'
Processor Information
Socket Designation: CPU 1
Type: Central Processor
Family: Core i5
Manufacturer: Intel
ID: A7 06 02 00 FF FB EB BF
Signature: Type 0, Family 6, Model 42, Stepping 7
Flags:
FPU (Floating-point unit on-chip)
VME (Virtual mode extension)
DE (Debugging extension)
PSE (Page size extension)
TSC (Time stamp counter)
MSR (Model specific registers)
PAE (Physical address extension)
MCE (Machine check exception)
CX8 (CMPXCHG8 instruction supported)
APIC (On-chip APIC hardware supported)
SEP (Fast system call)
MTRR (Memory type range registers)
PGE (Page global enable)
MCA (Machine check architecture)
CMOV (Conditional move instruction supported)
PAT (Page attribute table)
PSE-36 (36-bit page size extension)
CLFSH (CLFLUSH instruction supported)
DS (Debug store)
ACPI (ACPI supported)
MMX (MMX technology supported)
FXSR (FXSAVE and FXSTOR instructions supported)
SSE (Streaming SIMD extensions)
SSE2 (Streaming SIMD extensions 2)
SS (Self-snoop)
HTT (Multi-threading)
TM (Thermal monitor supported)
PBE (Pending break enabled)
Version: Intel(R) Core(TM) i5-2400 CPU @ 3.10GH
Voltage: 0.0 V
External Clock: 100 MHz
Max Speed: 4000 MHz
Current Speed: 3100 MHz
Status: Populated, Enabled
Upgrade: Other
L1 Cache Handle: 0x0005
L2 Cache Handle: 0x0006
L3 Cache Handle: 0x0007
Serial Number: Not Specified
Asset Tag: Not Specified
Part Number: Not Specified
Core Count: 4
Core Enabled: 4
Thread Count: 4
Characteristics:
64-bit capable
Handle 0x0005, DMI type 7, 19 bytes
Cache Information
Socket Designation: L1-Cache
Configuration: Enabled, Not Socketed, Level 1
Operational Mode: Write Back
Location: Internal
Installed Size: 256 kB
Maximum Size: 256 kB
Supported SRAM Types:
Other
Installed SRAM Type: Other
Speed: Unknown
Error Correction Type: None
System Type: Unified
Associativity: 8-way Set-associative
Handle 0x0006, DMI type 7, 19 bytes
Cache Information
Socket Designation: L2-Cache
Configuration: Enabled, Not Socketed, Level 2
Operational Mode: Varies With Memory Address
Location: Internal
Installed Size: 1024 kB
Maximum Size: 1024 kB
Supported SRAM Types:
Other
Installed SRAM Type: Other
---------------------------- Memory information -------------------------
# dmidecode | grep -A16 "Memory Device$"
Memory Device
Array Handle: 0x002E
Error Information Handle: Not Provided
Total Width: 64 bits
Data Width: 64 bits
Size: 8192 MB
Form Factor: DIMM
Set: None
Locator: ChannelA-DIMM0
Bank Locator: BANK 0
Type: DDR3
Type Detail: Synchronous
Speed: 1333 MHz
Manufacturer: Kingston
Serial Number: 8F2814C8
Asset Tag: 9876543210
Part Number: 99U5471-052.A00LF
--
Memory Device
Array Handle: 0x002E
Error Information Handle: Not Provided
Total Width: 64 bits
Data Width: 64 bits
Size: 8192 MB
Form Factor: DIMM
Set: None
Locator: ChannelB-DIMM0
Bank Locator: BANK 2
Type: DDR3
Type Detail: Synchronous
Speed: 1333 MHz
Manufacturer: Kingston
Serial Number: 0B169D83
Asset Tag: 9876543210
Part Number: 99U5471-038.A00LF
---------------------------- Matlab version -------------------------
>> ver
-------------------------------------------------------------------------------------------------------
MATLAB Version: 8.1.0.604 (R2013a)
MATLAB License Number: xxxxxx
Operating System: Linux 2.6.32-573.el6.x86_64 #1 SMP Thu Jul 23 15:44:03 UTC 2015 x86_64
Java Version: Java 1.6.0_17-b04 with Sun Microsystems Inc. Java HotSpot(TM) 64-Bit Server VM mixed mode
-------------------------------------------------------------------------------------------------------
  7 件のコメント
Adam
Adam 2016 年 4 月 5 日
You haven't shown any code. You would get that effect if you program a computationally intensive infinite loop so without seeing your code it is hard to suggest why it would
She
She 2016 年 4 月 5 日
編集済み: She 2016 年 4 月 5 日
Thank you!
In fact, the program is stopped at some breakpoints, without the influence of any potential infinite loop. The problem occurred when I tried to write some words info the *.m file.
Now, I solved this bug with Emacs calling matlab-shell mode which is some more complicated than Matlab itself, but I can freely edit and debug it, that's valuable.
Another optional way is, open Matlab with '-singleCompThread' option, it works well , also promise free edit and debug.
Thanks all!

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

回答 (0 件)

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by