help-octave
[Top][All Lists]

## Re: MinGW libblas [WAS: Re: Octave 3.6.0 on Windows XP plot fails.]

 From: Tatsuro MATSUOKA Subject: Re: MinGW libblas [WAS: Re: Octave 3.6.0 on Windows XP plot fails.] Date: Tue, 21 Feb 2012 08:27:13 +0900 (JST)

Hello Martin

Thank you for the explanation!

Regards

Tatsuro
--- On Mon, 2012/2/20, Martin Helm wrote:

> Am 20.02.2012 11:04, schrieb Tatsuro MATSUOKA:
> > Hello
> >
> > Please tell me which is correct to measure the performance.
> >
> > 1. n=2000; A=randn(n); B=randn(n);tic; C=A*B; t=toc, MFLOPS=2*n^3/t*1e-6
> >
> > 2. n=2000; A=randn(n); B=randn(n);ta=cputime; C=A*B; t=cputime-ta,
> > MFLOPS=2*n^3/t*1e-6
> >
> > Case 1 gives two - four times faster than that of the case 2.
> >
> > Example
> > octave:2> n=2000; A=randn(n); B=randn(n);tic; C=A*B; t=toc,
> > MFLOPS=2*n^3/t*1e-6
> > t =  0.70904
> > MFLOPS = 2.2566e+004
> > octave:3> n=2000; A=randn(n); B=randn(n);ta=cputime; C=A*B; t=cputime-ta,
> > MFLOPS=2*n^3/t*1e-6
> > t =  1.4040
> > MFLOPS = 1.1396e+004
> >
> >
> > Which test is correct to check the performance.
> >
> > Regards
> >
> > Tatsuro
> >
> The cputime sums together the time spent on all cpu's so if it runs lets
> say a total of 4sec till its complete parallel on 4 cpu's then cputime
> will give 16sec.
> You better use tic/toc.
>