mirror of
https://github.com/hermitcore/libhermit.git
synced 2025-03-09 00:00:03 +01:00
add support of old architectures, which doesn't support AVX
This commit is contained in:
parent
f1ba1aa30f
commit
5bdc732cd8
1 changed files with 14 additions and 2 deletions
|
@ -50,6 +50,11 @@
|
|||
#define RTE_MACHINE_CPUFLAG_AVX2
|
||||
#endif
|
||||
|
||||
// gcc defines this macro, if avx is enabled
|
||||
#ifdef __AVX__
|
||||
#define RTE_MACHINE_CPUFLAG_AVX
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -314,7 +319,7 @@ COPY_BLOCK_64_BACK31:
|
|||
goto COPY_BLOCK_64_BACK31;
|
||||
}
|
||||
|
||||
#else /* RTE_MACHINE_CPUFLAG_AVX2 */
|
||||
#elif defined(RTE_MACHINE_CPUFLAG_AVX)
|
||||
|
||||
/**
|
||||
* SSE & AVX implementation below
|
||||
|
@ -631,7 +636,14 @@ COPY_BLOCK_64_BACK15:
|
|||
goto COPY_BLOCK_64_BACK15;
|
||||
}
|
||||
|
||||
#endif /* RTE_MACHINE_CPUFLAG_AVX2 */
|
||||
#else
|
||||
|
||||
static inline void * rte_memcpy(void *dst, const void *src, size_t n)
|
||||
{
|
||||
return __builtin_memcpy(dst, src, n);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue