On 10/11/06, Robert McGwier <[EMAIL PROTECTED]> wrote:
> Philip Covington wrote:
> > On 10/11/06, Jim Lux <[EMAIL PROTECTED]> wrote:
> >
> >> At 06:44 AM 10/11/2006, Jim, W4ATK wrote:
> >>
> >>> Phil Covington wrote:
> >>>
> >>> "A lot of the perceived need for threading goes away when you get away 
> >>> from
> >>> straight
> >>> line procedural code."
> >>>
> >>> As an OLD machine language programmer, I am of the impression that 
> >>> "straight
> >>> line" code increases the speed of the particular routine(s) avoiding those
> >>> heavy far calls and the resultant stack operations. I think most 
> >>> optimizers
> >>> that offer the choice of size and/or speed generate straight line objects 
> >>> as
> >>> a means of increasing the speed..... Perhaps my rather ancient experience 
> >>> is
> >>> mistaken....
> >>>
> >> True in most cases.  But, might be a case of optimizing for a
> >> resource which we have an excess of, by spending a resource we are short 
> >> of.
> >>
> >>
> >
> > <snip>
> >
> > The interesting thing is that the JIT in .NET finds optimizations at
> > run time that could not easily be built into an optimizing compiler.
> >
> > I was pleasantly surprised when I could compute a FFT/IFFT in code
> > written in C# (based on Ooura's FFT code) as fast as using FFTW
> > library (even after running wisdom).  If you look through the SharpDSP
> > source you'll see that I did not use FFTW.
> >
>
> I suspect, but am not sure,  that you ran these tests before we changed
> the internals over to float and used the SIMD variants in FFTW.  It is
> very hard for me to imagine compiled code running faster than these hand
> optimized assembly "codelets".  That would be VERY interesting to
> investigate if it is true.
>
>
> > 73 de Phil N8VB
> >
> > _
>
> 73's
> Bob
> N4HY

Actually, I have and its pretty much a wash for FFTs up to 65536
points (the largest I tested).  I was trying to decide whether to use
FFTW or the FFT in SharpDSP with the Mercury spectrum analyzer.  I
recompiled SharpDSP in .NET 2 and since the speed is pretty much the
same I went with SharpDSP (which uses Ooura's FFT code).  The big
advantage is that I do not need to use another external library like
FFTW.

Also, in .NET 2 I removed all of the unsafe code with no performance
hit.  There really is no reason to use unsafe code in .NET 2.  I am
not surprised as much by the speed equivalence as I used to be when I
realized that the JIT will use SIMD operations if it finds a
performance gain.

Now I realize that my C# coded DSP won't run on a TI DSP or dsPIC like
DttSP can be modified to do, but it will run nicely on PCs in Windows
and Linux (using mono).

73 de Phil N8VB

_______________________________________________
FlexRadio mailing list
FlexRadio@flex-radio.biz
http://mail.flex-radio.biz/mailman/listinfo/flexradio_flex-radio.biz
Archive Link: http://www.mail-archive.com/flexradio%40flex-radio.biz/
FlexRadio Homepage: http://www.flex-radio.com

Reply via email to