MCPcopy Create free account
hub / github.com/Meituan-Dianping/SQLAdvisor / RoundupSize

Function RoundupSize

extra/yassl/taocrypt/src/integer.cpp:455–466  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

453static const unsigned int RoundupSizeTable[] = {2, 2, 2, 4, 4, 8, 8, 8, 8};
454
455static inline unsigned int RoundupSize(unsigned int n)
456{
457 if (n<=8)
458 return RoundupSizeTable[n];
459 else if (n<=16)
460 return 16;
461 else if (n<=32)
462 return 32;
463 else if (n<=64)
464 return 64;
465 else return 1U << BitPrecision(n-1);
466}
467
468
469static int Compare(const word *A, const word *B, unsigned int N)

Callers 1

AS2Function · 0.85

Calls 1

BitPrecisionFunction · 0.85

Tested by

no test coverage detected