Update comments

pull/853/head
Jeffrey Walton 2019-05-20 17:11:59 -04:00
parent b1b6ea5b78
commit c0cff24953
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
1 changed files with 4 additions and 3 deletions

View File

@ -176,9 +176,10 @@ ANONYMOUS_NAMESPACE_BEGIN
inline unsigned int CryptogamsArmCaps() inline unsigned int CryptogamsArmCaps()
{ {
// The Cryptogams code uses a global variable named CRYPTOGAMS_armcaps // The Cryptogams code uses a global variable named CRYPTOGAMS_armcaps
// for capabilities like ARMv7 and NEON. Storage is allocated in the // for capabilities like ARMv7 and NEON. We allocate storage for
// module. We still need to set CRYPTOGAMS_armcaps accordingly. // CRYPTOGAMS_armcaps, and the Cryptogams modules use our symbol.
// The Cryptogams code defines NEON as 1<<0; see ARMV7_NEON. // The Cryptogams code defines ARMV7_NEON as 1<<0, so we need to
// set the bits accordingly in CRYPTOGAMS_armcaps.
*const_cast<volatile unsigned int*>(&CRYPTOGAMS_armcaps) = CryptoPP::HasNEON() ? (1<<0) : 0; *const_cast<volatile unsigned int*>(&CRYPTOGAMS_armcaps) = CryptoPP::HasNEON() ? (1<<0) : 0;
return CRYPTOGAMS_armcaps; return CRYPTOGAMS_armcaps;