Fixes build on ARM.

This commit is contained in:
Andrea Mazzoleni 2013-12-30 10:13:10 +01:00
parent cda356dc75
commit 766ded42e9
2 changed files with 14 additions and 3 deletions

View file

@ -279,6 +279,7 @@ int raid_test_par(int mode, int nd, size_t size)
map[mac++] = raid_par2_sse2ext; map[mac++] = raid_par2_sse2ext;
#endif #endif
} }
#endif
if (mode == RAID_MODE_CAUCHY) { if (mode == RAID_MODE_CAUCHY) {
map[mac++] = raid_par3_int8; map[mac++] = raid_par3_int8;
@ -286,6 +287,7 @@ int raid_test_par(int mode, int nd, size_t size)
map[mac++] = raid_par5_int8; map[mac++] = raid_par5_int8;
map[mac++] = raid_par6_int8; map[mac++] = raid_par6_int8;
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_ssse3()) { if (raid_cpu_has_ssse3()) {
map[mac++] = raid_par3_ssse3; map[mac++] = raid_par3_ssse3;
map[mac++] = raid_par4_ssse3; map[mac++] = raid_par4_ssse3;
@ -300,9 +302,10 @@ int raid_test_par(int mode, int nd, size_t size)
} }
#endif #endif
} else { } else {
#if defined(__i386__) || defined(__x86_64__)
map[mac++] = raid_parz_int32; map[mac++] = raid_parz_int32;
map[mac++] = raid_parz_int64; map[mac++] = raid_parz_int64;
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_sse2()) { if (raid_cpu_has_sse2()) {
map[mac++] = raid_parz_sse2; map[mac++] = raid_parz_sse2;
#if defined(__x86_64__) #if defined(__x86_64__)

12
speed.c
View file

@ -147,8 +147,8 @@ void speed(void)
printf("\n"); printf("\n");
printf("Speed test using %u data buffers of %u bytes, for a total of %u KiB.\n", nd, size, nd * size / 1024); printf("Speed test using %u data buffers of %u bytes, for a total of %u KiB.\n", nd, size, nd * size / 1024);
printf("The reported value is the aggregate bandwidth of all data disks in MiB/s,\n"); printf("The reported value is the aggregate bandwidth of all data blocks in MiB/s,\n");
printf("not counting parity disks.\n"); printf("not counting parity blocks.\n");
printf("\n"); printf("\n");
printf("Memory write speed using the C memset() function:\n"); printf("Memory write speed using the C memset() function:\n");
@ -385,6 +385,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
printf("%8s", ""); printf("%8s", "");
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_sse2()) { if (raid_cpu_has_sse2()) {
printf("%8s", ""); printf("%8s", "");
@ -392,6 +393,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
#endif #endif
} }
#endif
#if defined(__i386__) || defined(__x86_64__) #if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_ssse3()) { if (raid_cpu_has_ssse3()) {
@ -429,6 +431,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
printf("%8s", ""); printf("%8s", "");
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_sse2()) { if (raid_cpu_has_sse2()) {
printf("%8s", ""); printf("%8s", "");
@ -436,6 +439,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
#endif #endif
} }
#endif
#if defined(__i386__) || defined(__x86_64__) #if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_ssse3()) { if (raid_cpu_has_ssse3()) {
@ -473,6 +477,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
printf("%8s", ""); printf("%8s", "");
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_sse2()) { if (raid_cpu_has_sse2()) {
printf("%8s", ""); printf("%8s", "");
@ -480,6 +485,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
#endif #endif
} }
#endif
#if defined(__i386__) || defined(__x86_64__) #if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_ssse3()) { if (raid_cpu_has_ssse3()) {
@ -517,6 +523,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
printf("%8s", ""); printf("%8s", "");
#if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_sse2()) { if (raid_cpu_has_sse2()) {
printf("%8s", ""); printf("%8s", "");
@ -524,6 +531,7 @@ void speed(void)
printf("%8s", ""); printf("%8s", "");
#endif #endif
} }
#endif
#if defined(__i386__) || defined(__x86_64__) #if defined(__i386__) || defined(__x86_64__)
if (raid_cpu_has_ssse3()) { if (raid_cpu_has_ssse3()) {