mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-06 11:34:38 +03:00
fix msvc compilation with new atomics
This commit is contained in:
parent
644e453709
commit
4df01218e2
4 changed files with 43 additions and 7 deletions
|
@ -49,6 +49,7 @@ static inline uint8_t mi_bsr32(uint32_t x) {
|
|||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
// Bit scan reverse: return the index of the highest bit.
|
||||
uint8_t _mi_bsr(uintptr_t x) {
|
||||
if (x == 0) return 0;
|
||||
|
@ -61,6 +62,8 @@ uint8_t _mi_bsr(uintptr_t x) {
|
|||
# error "define bsr for non-32 or 64-bit platforms"
|
||||
#endif
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
static inline size_t _mi_wsize_from_size(size_t size) {
|
||||
return (size + sizeof(uintptr_t) - 1) / sizeof(uintptr_t);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue