Skip to content

Commit

Permalink
Suppress 32bit/64bit warning
Browse files Browse the repository at this point in the history
Need a better solution for this where I can use a 64bit 1 which is 1UL on Linux and 1ULL on Windows.
  • Loading branch information
rgal committed Jan 28, 2021
1 parent 95f2345 commit c0d49e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler-rt/lib/scudo/standalone/size_class_map.h
Expand Up @@ -17,7 +17,7 @@ namespace scudo {

inline uptr scaledLog2(uptr Size, uptr ZeroLog, uptr LogBits) {
const uptr L = getMostSignificantSetBitIndex(Size);
const uptr LBits = (Size >> (L - LogBits)) - (1 << LogBits);
const uptr LBits = (Size >> (L - LogBits)) - (1ULL << LogBits);
const uptr HBits = (L - ZeroLog) << LogBits;
return LBits + HBits;
}
Expand Down

0 comments on commit c0d49e6

Please sign in to comment.