--- Olli Saarela wrote:
> I was looking for a CPU consuming loop in the C++ code, but there might
> actually be some in the script files. Does this help?
>
> *** __gnuplot_get_var__.m~ Tue Jun 9 23:22:14 2009
> --- __gnuplot_get_var__.m Mon Aug 3 13:52:35 2009
> ***************
> *** 125,135 ****
> fflush (ostream);
>
> str = {};
> while (isempty (str))
> str = char (fread (istream)');
> ! if (! isempty (str))
> str = regexp (str, "OCTAVE:.*", "match");
> str = str{end}(8:end);
> endif
> fclear (istream);
> endwhile
> --- 125,137 ----
> fflush (ostream);
>
> str = {};
> while (isempty (str))
> str = char (fread (istream)');
> ! if (isempty (str))
> ! sleep(0.05);
> ! else
> str = regexp (str, "OCTAVE:.*", "match");
> str = str{end}(8:end);
> endif
> fclear (istream);
> endwhile
>
>
> On my multicore machine the tic-toc timing is practically the same, but
> cputime() shows a significant speed-up.
>
First