Linking vDSP in 64bit
I'm trying to compile an link an fft routine using 64-bit on Snow Leopard (MacBook Pro). It compiles, links, and runs in 32-bit but does not link in 64-bit. Is there another Accelerate to use for 64-bit?
32-bit example:
______________________________________
cc -O -dalign -m32 -c -o testcfft1d.o testcfft1d.c
cc -O -dalign -m32 -c -o cfft1d_mac.o cfft1d_mac.c
cc -O -dalign -m32 testcfft1d.o cfft1d_mac.o -lm -framework Accelerate -lm -o testcfft1d_veclib
64-bit example
______________________________________
cc -O -dalign -m64 -c -o testcfft1d.o testcfft1d.c
cc -O -dalign -m64 -c -o cfft1d_mac.o cfft1d_mac.c
cfft1d_mac.c: In function ‘cfft1d_’:
cfft1d_mac.c:40: warning: assignment makes pointer from integer without a cast
cc -O -dalign -m64 testcfft1d.o cfft1d_mac.o -lm -framework Accelerate -lm -o testcfft1d_veclib
Undefined symbols:
"_ztoc", referenced from:
_cfft1d_ in cfft1d_mac.o
"_destroy_fftsetup", referenced from:
_cfft1d_cleanup_ in cfft1d_mac.o
"_ctoz", referenced from:
_cfft1d_ in cfft1d_mac.o
"_vsmul", referenced from:
_cfft1d_ in cfft1d_mac.o
"_create_fftsetup", referenced from:
_cfft1d_ in cfft1d_mac.o
"_fft_zip", referenced from:
_cfft1d_ in cfft1d_mac.o




RE: Linking vDSP in 64bit
hi-
I've done FFTs using the (usual) Accelerate framework (on Leopard/Snow Leopard) and it runs in 64-bit mode. I noticed (a long time ago) that a few symbols were not defined in 64 v.s 32 and I just found the substitute symbols (from my recollection some 32 bit API depreciated and were not found in 64 bit API). Don't know exactly why yours doesn't link, but it is definitely possible to run FFTs in 64 bit space.
thanks!-
-lance
vDSP
Hi Lance,
Could you send an example of a makefile to link the vDSP at 64-bit? The FFT is about 4 times faster than standard code so this would be VERY helpful. If you want to do radar interferometry, here is some code. A lot of the CPU time is spent doing fft's in 1 and 2 dimensions.
Thanks,
David
ftp://topex.ucsd.edu/pub/gmtsar/GMTSAR_V1.6.tar
Also example Haiti earthquake data in same location.
I realize there may be a
I realize there may be a fair bit of work to do in adapting an app for 64 bit - however shouldn't the built-in frameworks like Accelerate know the pointers are 64 bit, and use the appropriate binaries?
Sean Connery Movies
http://SeanConnerymovies.org/
You're using unpublished functions
The symbols that the compiler isn't finding are symbols that are not published APIs in the Accelerate framework, as evinced by the fact that they are not listed in any of the Accelerate headers.
Instead of ztoc( ), you should be using the documented vDSP_ztoc( ).
Instead of destroy_setup( ), you should be using the documented vDSP_destroy_setup( ).
Ditto for all of the other missing symbols that you encountered.
Basically, you need to go through your code and prepend all of these functions with the vDSP_ prefix.
More generally, the fact that code works in 32-bit mode doesn't mean that it's correct. If you use functions that are not published as part of the API documentation or headers, you should expect your code to be broken frequently.