fft.mak 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. define DEF_FFT
  2. FATE_DCT-$(CONFIG_DCT) += fate-dct1d-$(1) fate-idct1d-$(1)
  3. FATE_FFT-$(CONFIG_FFT) += fate-fft-$(1) fate-ifft-$(1)
  4. FATE_MDCT-$(CONFIG_MDCT) += fate-mdct-$(1) fate-imdct-$(1)
  5. FATE_RDFT-$(CONFIG_RDFT) += fate-rdft-$(1) fate-irdft-$(1)
  6. fate-fft-$(N): ARGS = -n$(1)
  7. fate-ifft-$(N): ARGS = -n$(1) -i
  8. fate-mdct-$(N): ARGS = -n$(1) -m
  9. fate-imdct-$(N): ARGS = -n$(1) -m -i
  10. fate-rdft-$(N): ARGS = -n$(1) -r
  11. fate-irdft-$(N): ARGS = -n$(1) -r -i
  12. fate-dct1d-$(N): ARGS = -n$(1) -d
  13. fate-idct1d-$(N): ARGS = -n$(1) -d -i
  14. endef
  15. $(foreach N, 4 5 6 7 8 9 10 11 12, $(eval $(call DEF_FFT,$(N))))
  16. fate-dct-float: $(FATE_DCT-yes)
  17. fate-fft-float: $(FATE_FFT-yes)
  18. fate-mdct-float: $(FATE_MDCT-yes)
  19. fate-rdft-float: $(FATE_RDFT-yes)
  20. FATE_FFT_ALL = $(FATE_DCT-yes) $(FATE_FFT-yes) $(FATE_MDCT-yes) $(FATE_RDFT-yes)
  21. $(FATE_FFT_ALL): libavcodec/tests/fft$(EXESUF)
  22. $(FATE_FFT_ALL): CMD = run libavcodec/tests/fft$(EXESUF) $(CPUFLAGS:%=-c%) $(ARGS)
  23. define DEF_FFT_FIXED
  24. FATE_FFT_FIXED-$(CONFIG_FFT) += fate-fft-fixed-$(1) fate-ifft-fixed-$(1)
  25. FATE_MDCT_FIXED-$(CONFIG_MDCT) += fate-mdct-fixed-$(1) fate-imdct-fixed-$(1)
  26. fate-fft-fixed-$(1): ARGS = -n$(1)
  27. fate-ifft-fixed-$(1): ARGS = -n$(1) -i
  28. fate-mdct-fixed-$(1): ARGS = -n$(1) -m
  29. fate-imdct-fixed-$(1): ARGS = -n$(1) -m -i
  30. endef
  31. $(foreach N, 4 5 6 7 8 9 10 11 12, $(eval $(call DEF_FFT_FIXED,$(N))))
  32. fate-fft-fixed: $(FATE_FFT_FIXED-yes)
  33. fate-mdct-fixed: $(FATE_MDCT_FIXED-yes)
  34. FATE_FFT_FIXED_ALL = $(FATE_FFT_FIXED-yes) $(FATE_MDCT_FIXED-yes)
  35. $(FATE_FFT_FIXED_ALL): libavcodec/tests/fft-fixed$(EXESUF)
  36. $(FATE_FFT_FIXED_ALL): CMD = run libavcodec/tests/fft-fixed$(EXESUF) $(CPUFLAGS:%=-c%) $(ARGS)
  37. $(FATE_FFT_ALL) $(FATE_FFT_FIXED_ALL): CMP = null
  38. define DEF_FFT_FIXED32
  39. FATE_FFT_FIXED32 += fate-fft-fixed32-$(1) fate-ifft-fixed32-$(1) \
  40. fate-mdct-fixed32-$(1) fate-imdct-fixed32-$(1)
  41. fate-fft-fixed32-$(1): ARGS = -n$(1)
  42. fate-ifft-fixed32-$(1): ARGS = -n$(1) -i
  43. #fate-mdct-fixed32-$(1): ARGS = -n$(1) -m
  44. fate-imdct-fixed32-$(1): ARGS = -n$(1) -m -i
  45. endef
  46. $(foreach N, 4 5 6 7 8 9 10 11 12, $(eval $(call DEF_FFT_FIXED32,$(N))))
  47. fate-fft-fixed32: $(FATE_FFT_FIXED32)
  48. $(FATE_FFT_FIXED32): libavcodec/tests/fft-fixed32$(EXESUF)
  49. $(FATE_FFT_FIXED32): CMD = run libavcodec/tests/fft-fixed32$(EXESUF) $(CPUFLAGS:%=-c%) $(ARGS)
  50. $(FATE_FFT_FIXED32): CMP = null
  51. define DEF_AV_FFT
  52. FATE_AV_DCT-$(CONFIG_DCT) += fate-av-dct1d-$(1) fate-av-idct1d-$(1)
  53. FATE_AV_FFT-$(CONFIG_FFT) += fate-av-fft-$(1) fate-av-ifft-$(1)
  54. FATE_AV_MDCT-$(CONFIG_MDCT) += fate-av-mdct-$(1) fate-av-imdct-$(1)
  55. FATE_AV_RDFT-$(CONFIG_RDFT) += fate-av-rdft-$(1) fate-av-irdft-$(1)
  56. fate-av-fft-$(N): ARGS = -n$(1)
  57. fate-av-ifft-$(N): ARGS = -n$(1) -i
  58. fate-av-mdct-$(N): ARGS = -n$(1) -m
  59. fate-av-imdct-$(N): ARGS = -n$(1) -m -i
  60. fate-av-rdft-$(N): ARGS = -n$(1) -r
  61. fate-av-irdft-$(N): ARGS = -n$(1) -r -i
  62. fate-av-dct1d-$(N): ARGS = -n$(1) -d
  63. fate-av-idct1d-$(N): ARGS = -n$(1) -d -i
  64. endef
  65. $(foreach N, 4 5 6 7 8 9 10 11 12, $(eval $(call DEF_AV_FFT,$(N))))
  66. fate-av-dct-float: $(FATE_AV_DCT-yes)
  67. fate-av-fft-float: $(FATE_AV_FFT-yes)
  68. fate-av-mdct-float: $(FATE_AV_MDCT-yes)
  69. fate-av-rdft-float: $(FATE_AV_RDFT-yes)
  70. FATE_AV_FFT_ALL = $(FATE_AV_DCT-yes) $(FATE_AV_FFT-yes) $(FATE_AV_MDCT-yes) $(FATE_AV_RDFT-yes)
  71. $(FATE_AV_FFT_ALL): libavcodec/tests/avfft$(EXESUF)
  72. $(FATE_AV_FFT_ALL): CMD = run libavcodec/tests/avfft$(EXESUF) $(CPUFLAGS:%=-c%) $(ARGS)
  73. $(FATE_AV_FFT_ALL): CMP = null
  74. fate-dct: fate-dct-float
  75. fate-fft: fate-fft-float fate-fft-fixed fate-fft-fixed32
  76. fate-mdct: fate-mdct-float fate-mdct-fixed
  77. fate-rdft: fate-rdft-float
  78. FATE-$(call ALLYES, AVCODEC FFT MDCT) += $(FATE_FFT_ALL) $(FATE_FFT_FIXED_ALL) $(FATE_FFT_FIXED32) $(FATE_AV_FFT_ALL)
  79. fate-fft-all: $(FATE_FFT_ALL) $(FATE_FFT_FIXED_ALL) $(FATE_FFT_FIXED32) $(FATE_AV_FFT_ALL)