Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which part of my matlab code is multi-threaded?

Is there a way to do some profiling to check which part of my code uses several thread?

I have a matlab code, where I run it, I can see on the system monitor that several cores are used. But I cannot figure out which part of the code is multi-threaded...

I wonder if the profiler can find it out, or some other tool...

like image 753
Oli Avatar asked Feb 16 '12 18:02

Oli


1 Answers

A round about way, is to search for known multi-threaded functions. Here's the best list I know of for that: http://www.walkingrandomly.com/?p=1894. Also note that operations like, a.*b, or sin(a) will be multi-threaded if a and/or b are large enough matrices.

You can also use the profiler to reduce your search space. If most of your code is running multi-threaded most of the time, then wherever your code is spending time the most is likely where the multi-threading is occurring....

like image 193
John Avatar answered Sep 28 '22 07:09

John