mirror of
https://github.com/aaru-dps/Aaru.Checksums.Native.git
synced 2025-12-16 19:24:29 +00:00
Add ARM SIMD VMULL implementation of CRC32.
This commit is contained in:
6
crc32.c
6
crc32.c
@@ -21,7 +21,6 @@
|
||||
|
||||
#include "library.h"
|
||||
#include "crc32.h"
|
||||
#include "simd.h"
|
||||
|
||||
AARU_EXPORT crc32_ctx* AARU_CALL crc32_init(void)
|
||||
{
|
||||
@@ -55,6 +54,11 @@ AARU_EXPORT int AARU_CALL crc32_update(crc32_ctx* ctx, const uint8_t* data, uint
|
||||
|
||||
return 0;
|
||||
}
|
||||
if(have_neon())
|
||||
{
|
||||
ctx->crc = ~crc32_vmull(data, len, ~ctx->crc);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
// Unroll according to Intel slicing by uint8_t
|
||||
|
||||
Reference in New Issue
Block a user