Removed alignemnt from RecordIdentifiers
This commit is contained in:
parent
f68724c7b9
commit
f566edc642
|
@ -56,7 +56,7 @@ class Metadata
|
||||||
{
|
{
|
||||||
_begin_timestamp.store(other._begin_timestamp.load());
|
_begin_timestamp.store(other._begin_timestamp.load());
|
||||||
_end_timestamp.store(other._end_timestamp.load());
|
_end_timestamp.store(other._end_timestamp.load());
|
||||||
_next_in_version_chain.store(other._next_in_version_chain.load());
|
_next_in_version_chain = other._next_in_version_chain;
|
||||||
}
|
}
|
||||||
|
|
||||||
~Metadata() = default;
|
~Metadata() = default;
|
||||||
|
@ -83,7 +83,7 @@ class Metadata
|
||||||
*/
|
*/
|
||||||
[[nodiscard]] storage::RecordIdentifier next_in_version_chain() const
|
[[nodiscard]] storage::RecordIdentifier next_in_version_chain() const
|
||||||
{
|
{
|
||||||
return _next_in_version_chain.load();
|
return _next_in_version_chain;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -136,7 +136,7 @@ class Metadata
|
||||||
*/
|
*/
|
||||||
void next_in_version_chain(const storage::RecordIdentifier next)
|
void next_in_version_chain(const storage::RecordIdentifier next)
|
||||||
{
|
{
|
||||||
_next_in_version_chain.store(next);
|
_next_in_version_chain = next;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -158,6 +158,6 @@ class Metadata
|
||||||
std::atomic<timestamp> _end_timestamp;
|
std::atomic<timestamp> _end_timestamp;
|
||||||
|
|
||||||
// Pointer to the next record in version chain.
|
// Pointer to the next record in version chain.
|
||||||
std::atomic<storage::RecordIdentifier> _next_in_version_chain;
|
storage::RecordIdentifier _next_in_version_chain;
|
||||||
};
|
};
|
||||||
} // namespace beedb::concurrency
|
} // namespace beedb::concurrency
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
|
|
||||||
namespace beedb::storage
|
namespace beedb::storage
|
||||||
{
|
{
|
||||||
class alignas(64) RecordIdentifier
|
class RecordIdentifier
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static_assert(sizeof(Page::id_t) + sizeof(std::uint16_t) <= sizeof(std::uint64_t));
|
static_assert(sizeof(Page::id_t) + sizeof(std::uint16_t) <= sizeof(std::uint64_t));
|
||||||
|
|
Loading…
Reference in New Issue