[NFC][sanitizer] constexpr StackStore::StackStore()
This commit is contained in:
parent
bb50e97103
commit
8210948a46
|
|
@ -22,6 +22,8 @@ namespace __sanitizer {
|
||||||
|
|
||||||
class StackStore {
|
class StackStore {
|
||||||
public:
|
public:
|
||||||
|
constexpr StackStore() = default;
|
||||||
|
|
||||||
using Id = uptr;
|
using Id = uptr;
|
||||||
|
|
||||||
Id store(const StackTrace &trace);
|
Id store(const StackTrace &trace);
|
||||||
|
|
@ -34,17 +36,17 @@ class StackStore {
|
||||||
uptr *alloc(uptr count = 1);
|
uptr *alloc(uptr count = 1);
|
||||||
uptr *tryAlloc(uptr count);
|
uptr *tryAlloc(uptr count);
|
||||||
uptr *refillAndAlloc(uptr count);
|
uptr *refillAndAlloc(uptr count);
|
||||||
mutable StaticSpinMutex mtx; // Protects alloc of new blocks.
|
mutable StaticSpinMutex mtx = {}; // Protects alloc of new blocks.
|
||||||
atomic_uintptr_t region_pos; // Region allocator for Node's.
|
atomic_uintptr_t region_pos = {}; // Region allocator for Node's.
|
||||||
atomic_uintptr_t region_end;
|
atomic_uintptr_t region_end = {};
|
||||||
atomic_uintptr_t mapped_size;
|
atomic_uintptr_t mapped_size = {};
|
||||||
|
|
||||||
struct BlockInfo {
|
struct BlockInfo {
|
||||||
const BlockInfo *next;
|
const BlockInfo *next;
|
||||||
uptr ptr;
|
uptr ptr;
|
||||||
uptr size;
|
uptr size;
|
||||||
};
|
};
|
||||||
const BlockInfo *curr;
|
const BlockInfo *curr = nullptr;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace __sanitizer
|
} // namespace __sanitizer
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue