summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorAnthony Blake <anthonix@me.com>2013-04-22 16:45:17 +1200
committerAnthony Blake <anthonix@me.com>2013-04-22 16:45:17 +1200
commit7b3907cff81fb82380787e63e4304fb8af807c0c (patch)
tree11ae035cd02aab22e1a4069737fb6f422a7531eb /tests
parenta45464980b8de7faef21eb46479f7e09fd056441 (diff)
downloadffts-7b3907cff81fb82380787e63e4304fb8af807c0c.zip
ffts-7b3907cff81fb82380787e63e4304fb8af807c0c.tar.gz
Fixed up the smaller VFP transforms. Inverse VFP and real/nd VFP still not working yet.
Diffstat (limited to 'tests')
-rw-r--r--tests/test.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/tests/test.c b/tests/test.c
index 31437ac..f3ffcf7 100644
--- a/tests/test.c
+++ b/tests/test.c
@@ -33,8 +33,8 @@
#include <math.h>
#ifdef __ARM_NEON__
-
-#else
+#endif
+#ifdef HAVE_SSE
#include <xmmintrin.h>
#endif
@@ -91,12 +91,12 @@ float impulse_error(int N, int sign, float *data) {
int
test_transform(int n, int sign) {
-#ifdef __ARM_NEON__
- float __attribute__ ((aligned(32))) *input = valloc(2 * n * sizeof(float));
- float __attribute__ ((aligned(32))) *output = valloc(2 * n * sizeof(float));
-#else
+#ifdef HAVE_SSE
float __attribute__ ((aligned(32))) *input = _mm_malloc(2 * n * sizeof(float), 32);
float __attribute__ ((aligned(32))) *output = _mm_malloc(2 * n * sizeof(float), 32);
+#else
+ float __attribute__ ((aligned(32))) *input = valloc(2 * n * sizeof(float));
+ float __attribute__ ((aligned(32))) *output = valloc(2 * n * sizeof(float));
#endif
int i;
for(i=0;i<n;i++) {
@@ -127,12 +127,12 @@ main(int argc, char *argv[]) {
int n = atoi(argv[1]);
int sign = atoi(argv[2]);
-#ifdef __ARM_NEON__
- float __attribute__ ((aligned(32))) *input = valloc(2 * n * sizeof(float));
- float __attribute__ ((aligned(32))) *output = valloc(2 * n * sizeof(float));
-#else
+#ifdef HAVE_SSE
float __attribute__ ((aligned(32))) *input = _mm_malloc(2 * n * sizeof(float), 32);
float __attribute__ ((aligned(32))) *output = _mm_malloc(2 * n * sizeof(float), 32);
+#else
+ float __attribute__ ((aligned(32))) *input = valloc(2 * n * sizeof(float));
+ float __attribute__ ((aligned(32))) *output = valloc(2 * n * sizeof(float));
#endif
int i;
for(i=0;i<n;i++) {
@@ -152,12 +152,12 @@ main(int argc, char *argv[]) {
return 0;
}
-#ifdef __ARM_NEON__
- free(input);
- free(output);
-#else
+#ifdef HAVE_NEON
_mm_free(input);
_mm_free(output);
+#else
+ free(input);
+ free(output);
#endif
}else{
OpenPOWER on IntegriCloud