[Scipy-tickets] [SciPy] #408: Cleaning up fftpack sources

SciPy scipy-tickets@scipy....
Thu May 17 22:52:26 CDT 2007


#408: Cleaning up fftpack sources
---------------------------+------------------------------------------------
 Reporter:  cdavid         |        Owner:  somebody
     Type:  enhancement    |       Status:  new     
 Priority:  normal         |    Milestone:          
Component:  scipy.fftpack  |      Version:          
 Severity:  normal         |   Resolution:          
 Keywords:                 |  
---------------------------+------------------------------------------------
Comment (by cdavid):

 I agree that using custom generation script is not good if I could use
 already existing tool in numpy. What generation tools are you talking
 about: the ones I know are in numpy/core, used to generate the C api and
 type dependant function, but I didn't find any other general functionality
 (I basically need to generate source from a template where the function
 names are changed, not the type of function's arguments).

 About using C preprocessor, I am far from being a C preprocessor guru, but
 I think it would be quite difficult to do the generation with the C
 preprocessor, because you cannot use macro within macro (eg use an #ifdef
 inside a macro, and I need to special case each backend if WITH_DJBFFT is
 defined); that's why I gave up on using the C preprocessor.

 The goal of cleaning fftpack is to make it easier to add new backends.
 With this patch, all you have to do is to create your own file, and
 declare it when generating the code: the generation tool takes care of
 modifying other backends if necessary (mainly djbfft). If I had to use the
 C preprocessor, then the writer of a new backend would have to care about
 other backends as well.

-- 
Ticket URL: <http://projects.scipy.org/scipy/scipy/ticket/408#comment:3>
SciPy <http://www.scipy.org/>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list