From: Jeffrey Wu on
"Alex Gardner" <alexg(a)ualberta.ca> wrote in message <h4l0h2$cv5$1(a)fred.mathworks.com>...
> I've been running the same Matlab script on both a Mac (OS X) and a PC (Vista). The processor speeds of the 2 computers are nearly identical. When I run the scrip from the Matlab command window on my Mac the 'toc' 'toc' lapsed time is about 25% (45 sec) faster than on the PC. When I use Matlab's profiler on my Mac the 'profiler time' is about twice the time of the PC's profiler time. Why would a scrip that runs faster on a Mac take twice as long to profile when compared to a PC?

Similar problem here. I'm running Matlab on a Mac, and I have a function that (given the same inputs, of course) takes about 1.5 seconds to run if the profiler is off (measured with tic and toc), and more than 45 seconds to run if the profiler is on!