mirror of https://gitee.com/bigwinds/arangodb
Fixed data layout of cache buckets for 32-bit systems.
This commit is contained in:
parent
837763097a
commit
f4a8b6911f
|
@ -54,7 +54,7 @@ struct PlainBucket {
|
||||||
|
|
||||||
// padding, if necessary?
|
// padding, if necessary?
|
||||||
#ifdef TRI_PADDING_32
|
#ifdef TRI_PADDING_32
|
||||||
uint32_t _padding[3];
|
uint32_t _padding[slotsData];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
|
@ -29,6 +29,8 @@
|
||||||
#include "Cache/Common.h"
|
#include "Cache/Common.h"
|
||||||
#include "Cache/State.h"
|
#include "Cache/State.h"
|
||||||
|
|
||||||
|
#include <stddef.h>
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <atomic>
|
#include <atomic>
|
||||||
|
|
||||||
|
@ -53,16 +55,16 @@ struct TransactionalBucket {
|
||||||
uint32_t _cachedHashes[slotsData];
|
uint32_t _cachedHashes[slotsData];
|
||||||
CachedValue* _cachedData[slotsData];
|
CachedValue* _cachedData[slotsData];
|
||||||
|
|
||||||
|
// padding, if necessary?
|
||||||
|
#ifdef TRI_PADDING_32
|
||||||
|
uint32_t _padding[slotsData];
|
||||||
|
#endif
|
||||||
|
|
||||||
// blacklist entries for transactional semantics
|
// blacklist entries for transactional semantics
|
||||||
static constexpr size_t slotsBlacklist = 4;
|
static constexpr size_t slotsBlacklist = 4;
|
||||||
uint32_t _blacklistHashes[slotsBlacklist];
|
uint32_t _blacklistHashes[slotsBlacklist];
|
||||||
uint64_t _blacklistTerm;
|
uint64_t _blacklistTerm;
|
||||||
|
|
||||||
// padding, if necessary?
|
|
||||||
#ifdef TRI_PADDING_32
|
|
||||||
uint32_t _padding[3];
|
|
||||||
#endif
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
/// @brief Initialize an empty bucket.
|
/// @brief Initialize an empty bucket.
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
Loading…
Reference in New Issue