allocator: "padding" field for alloc_metadata_t, static_assert on sizeof
This commit is contained in:
@@ -15,10 +15,14 @@
|
|||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
u64 padding : 56;
|
||||||
|
tag_t tag : 8;
|
||||||
u64 references;
|
u64 references;
|
||||||
tag_t tag : 8;
|
|
||||||
} alloc_metadata_t;
|
} alloc_metadata_t;
|
||||||
|
|
||||||
|
static_assert(sizeof(alloc_metadata_t) == 16,
|
||||||
|
"16 byte metadata required for alignment purposes");
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
alloc_metadata_t metadata;
|
alloc_metadata_t metadata;
|
||||||
|
|||||||
Reference in New Issue
Block a user