ext-cryptopp/TestPrograms/test_arm_crc.cxx
Jeffrey Walton 60eedb97ba
Fix ARM headers and Android compile (PR #896)
* Test fix ARM headers
This problem has been festering for some time. The header file includes are slightly different than the ISA options. Some platforms need an include, others don't.

* Fix cryptest-android.sh and cryptest-ios.sh

* Fix MSVC ARM32 and ARM64 compile

* Split ARM32 and ARM64 recipes in GNUmakefile
2019-10-16 21:00:45 -04:00

24 lines
473 B
C++

#include <arm_neon.h>
#include <stdint.h>
// test_acle.h determines if this is available. Then,
// -DCRYPTOPP_ARM_ACLE_HEADER=0 is added to CXXFLAGS
// if the ACLE header is not available.
#if (CRYPTOPP_ARM_ACLE_HEADER)
# include <arm_acle.h>
#endif
int main(int argc, char* argv[])
{
uint32_t w=0xffffffff;
w = __crc32w(w,w);
w = __crc32h(w,w);
w = __crc32b(w,w);
w = __crc32cw(w,w);
w = __crc32ch(w,w);
w = __crc32cb(w,w);
return 0;
}