Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: MATLAB Profiler
Date: Wed, 31 Oct 2012 20:57:08 +0000 (UTC)
Organization: TACT Computer Systems Ltd
Lines: 15
Message-ID: <k6s3b4$e14$1@newscl01ah.mathworks.com>
References: <k6pjos$ud$1@newscl01ah.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: www-01-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: newscl01ah.mathworks.com 1351717028 14372 172.30.248.46 (31 Oct 2012 20:57:08 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Wed, 31 Oct 2012 20:57:08 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 642467
Xref: news.mathworks.com comp.soft-sys.matlab:781774

"Elnaz " <ebsadeghian@gmail.com> wrote in message <k6pjos$ud$1@newscl01ah.mathworks.com>...
> Dear all,
> 
> Using the profiler with CPU time, I'm getting different timing lengths every time I run the exact same code with everything fixed. Am I missing something?
> My goal is to improve the speed of my code which is highly needed.
> 
> Elnaz

For the past 4 years at least, the profiler has an undocumented bug that causes the CPU-time profiling to actually measure wall-clock timings.

See http://undocumentedmatlab.com/blog/buggy-profiler-option/

Yair Altman 
http://UndocumentedMatlab.com