[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW
From: |
Tatsuro MATSUOKA |
Subject: |
Re: Plotting with 3.2.0 on Windows is SLOOOOOOWWWW |
Date: |
Sat, 1 Aug 2009 16:10:27 +0900 (JST) |
Hello
I have made a patch to lo-sysdep.cc at the end of file. For the example by
Matthiaas Brennwldd
N = 100;
n = 2;
m = 2;
tic
for i = 1:n*m
x = rand (2,N);
subplot (n,m,i);
plot (x(1,:),x(2,:));
end
toc
Time for plot is about 8 seconds and 2 second after that.
(CPU CeleronM 1.3GHz, XP home 512 MB Memory).
Before patch it took 5-7 minutes!!! Too slow.
However, is it reanable each child process created by octave_popen2 always has
ABOVE_NORMAL_PRIORITY_CLASS?
The slowness at this time occurred because the octave-3.2.0 is heavy task for 1
core system, which
share almost all cpu activities.
I cannot judge this patch is appropriate so that I would like to heart the
opinion by those who are
much experience and knowledge for the windows programing.
Regards
Tatsuro
**************************
--- a/liboctave/lo-sysdep.cc 2009-05-25 15:04:58 +0900
+++ b/liboctave/lo-sysdep.cc 2009-08-01 15:48:55 +0900
@@ -159,6 +159,7 @@
msg = "popen2: process creation failed";
return -1;
}
+ SetPriorityClass(pi.hProcess, ABOVE_NORMAL_PRIORITY_CLASS);
pid = pi.dwProcessId;
CloseHandle (childRead);
--------------------------------------
Power up the Internet with Yahoo! Toolbar.
http://pr.mail.yahoo.co.jp/toolbar/