Forum > Windows

optimized sources

<< < (45/179) > >>

_heinz:
Hi Jason,
benchmark.cpp ------>
-----------------------------------------------------------------------------------------------
      switch ( bench_list[idx].token )
         {
         case _FFT:
            #if defined( USE_IPP )
               ippsFFTInv_CToC_32fc(
                  ( Ipp32fc * ) workBuf,   // This is the source data, this is not overwritten
                  ( Ipp32fc * ) out_buf,   // This is some other Buffer destination
                                    // no memcpy required
                  FftSpec,
                  NULL );
            #endif //seti_britta:
            #if defined( USE_FFTWF )
            fftwf_execute_dft( da_fft_plan, (sah_complex *)&in_buf[0], (sah_complex *)&out_buf );
            #endif
--------------------------------------------------------------------------
it compiles well ------>
Copyright (C) Microsoft Corporation.  All rights reserved.
cl /Od /Ob2 /Oi /Ot /Oy /GT /I "../../../boinc/win_build" /I ".." /I "..\.." /I "..\..\..\boinc\lib" /I "../../../boinc/api" /I "../../db" /I "C:\I\SC\vs90\seti_boinc_2k3_2.2B-Ben-Joe\client\Optimizer" /I "C:\I\INTEL\IPP\5.2_beta\ia32\tools\staticlib" /I "C:\I\INTEL\IPP\5.2_beta\ia32\include" /D "USE_IPP" /D "USE_SSE2" /D "WIN32" /D "_WIN32" /D "_WINDOWS" /D "_CONSOLE" /D "_DEBUG" /D "_LIB" /D "_MT" /D "CLIENT" /D "NBOINC_APP_GRAPHICS" /D "_UNICODE" /D "UNICODE" /D "_VC80_UPGRADE=0x0710" /D "_MBCS" /GF /FD /EHsc /MTd /Zp16 /Gy /Fo"Release32-NOGFX\\" /Fd"Release32-NOGFX\vc90.pdb" /W3 /c /Wp64 /Zi /Gd /TP /FI "win-config.h" ".\benchmark.cpp"
benchmark.cpp
-----IPP-----
-----SSE2-----
-----ipp-----
-----sse2-----
Build log was saved at "file://c:\I\SC\vs90\seti_boinc_2k3_2.2B-Ben-Joe\client\Optimizer\Release32-NOGFX\BuildLog.htm"
Optimizer - 0 error(s), 0 warning(s)
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
tried this as you prevent it ---->
            #if !(defined(USE_IPP) | defined(USE_FFTWF))
                  //statements to be used if neither FFTW or IPP
                  //memcopy is here, this should only run for builds with no IPP or FFTW .... or if the following IPP call wasn't updated
                        memcpy( WorkArea, &ChirpedData[CurrentSub], int(fftlen * sizeof(sah_complex)) );
                    #endif
---------------------------------------------------------------------------------------
analyzeFuncs.cpp
-----IPP-----
-----SSE2-----
..\analyzeFuncs.cpp(630) : error C2065: 'WorkArea' : undeclared identifier
..\analyzeFuncs.cpp(642) : error C2065: 'WorkArea' : undeclared identifier
..\analyzeFuncs.cpp(642) : error C2065: 'WorkArea' : undeclared identifier
..\analyzeFuncs.cpp(653) : error C2065: 'WorkArea' : undeclared identifier
--------------------------------------------------------------------------------------------------------
627                     #if defined( USE_IPP )
628                         ippsFFTInv_CToC_32fc(
629                            ( Ipp32fc * ) &ChirpedData[CurrentSub], // to direct source for out of place
630                     ( Ipp32fc * ) WorkArea, // leave as same destination
                     FftSpec[FftNum],
                     FftBuf );

-------------------------------------------------------------------------------------------------------------------------------
hmm.... will use the old statement then it compiles....
heinz

Jason G:
In Benchmark.cpp, I am worried that will not work in the case we use a zero fill instead of workBuf as the source.

In AnalyzeFuncs, I am looking where/ why your WorkArea has gone  :o

Jason G:
Are you missing this line above the   memcpy #if block in that one place?

          sah_complex *WorkArea = &WorkData[iC * fftlen / 2];  // assume sah_complex 2 floats
          #if !(defined(USE_IPP) | defined(USE_FFTWF))
                  //statements to be used if neither FFTW or IPP
                   memcpy( WorkArea, &ChirpedData[CurrentSub], int(fftlen * sizeof(sah_complex)) );
          #endif

You have different source to me! ( different line numbers! ) uh oh

[PS: If it is breaking your source to try this then I suggest to stop and reverse :D It is a nice idea that may or may not show any benefit in the long run, but needs more planning, consideration and testing before wholesale code changes are made. Baby steps are better IMO, Besides,  I break enough of my own code  ;)  ]

_heinz:
Merci for the comments,
in this way it compiles ---->
------------------------------------------------------------------------------------------------------
                    CurrentSub = fftlen * (ifft + iC);
                /*   sah_complex *WorkArea = &WorkData[iC * fftlen / 2];*/  // assume sah_complex 2 floats
            // seti_britta: do fftlen / 2 out of the loop, where fftlen get its value
               sah_complex *WorkArea = &WorkData[iC * fftlen_half];  // assume sah_complex 2 floats               #ifndef USE_FFTW      // FFTW & IPP now use out of place transforms
               // memcopy no longer necessary,
                    //    memcpy( WorkArea, &ChirpedData[CurrentSub], int(fftlen * sizeof(sah_complex)) );
                    #endif

                    #if defined( USE_IPP )
                        ippsFFTInv_CToC_32fc(
                            ( Ipp32fc * ) &ChirpedData[CurrentSub], // to direct source for out of place
                     ( Ipp32fc * ) WorkArea, // leave as same destination
                     FftSpec[FftNum],
                     FftBuf );
                    #elif defined( USE_FFTWF )
                        fftwf_execute_dft( analysis_plans[FftNum], &ChirpedData[CurrentSub], WorkArea );
                    #else // replace time with freq - ooura FFT
               // seti_britta: take mult wit 2 out of the loop, where fftlen get its value
                    /*  cdft( fftlen * 2, 1, WorkArea, BitRevTab[FftNum], CoeffTab[FftNum] ); */
                  cdft( fftlen_m2, 1, WorkArea, BitRevTab[FftNum], CoeffTab[FftNum] );
                    #endif
--------------------------------------------------------------------------------------------------------
the yellow line was there....
yes very different linenumbers, I give the analyzeFuncs.cpp a new structure......
I will have a look at benchmark again.... make a trigger for the case we use a zero fill.
heinz

heinz

Jason G:

--- Quote from: seti_britta on 28 Oct 2007, 11:02:40 am ---the yellow line was there....

--- End quote ---
    and still "undefined" variable WorkArea?,  that is wierd  :o


--- Quote ---yes very different linenumbers, I give the analyzeFuncs.cpp a new structure......
I will have a look at benchmark again.... make a trigger for the case we use a zero fill.
heinz

--- End quote ---
Ahh that's right, the improved model you showed me ... that's some good stuff mmm.

I'll take a look in mine at the WorkArea part,  I think may be in an inner loop and may be a most important place if something is to show a change in tests.

Jason

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version