mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 06:04:57 +00:00
Revert "AK: Align Function storage to __BIGGEST_ALIGNMENT__ outside…
…kernel"
This reverts commit d4d92184b3
.
The alignemnt requirements imposed by this are overkill at best and
ridiculous at worst, a future commit will tackle this problem in a
different, more space-efficient way.
This commit is contained in:
parent
06d05b3c55
commit
5e0a28c947
1 changed files with 1 additions and 3 deletions
|
@ -284,13 +284,11 @@ private:
|
|||
#ifndef KERNEL
|
||||
// Empirically determined to fit most lambdas and functions.
|
||||
static constexpr size_t inline_capacity = 4 * sizeof(void*);
|
||||
alignas(__BIGGEST_ALIGNMENT__) u8 m_storage[inline_capacity];
|
||||
#else
|
||||
// FIXME: Try to decrease this.
|
||||
static constexpr size_t inline_capacity = 6 * sizeof(void*);
|
||||
// In the Kernel nothing has an alignment > alignof(void*).
|
||||
alignas(alignof(void*)) u8 m_storage[inline_capacity];
|
||||
#endif
|
||||
alignas(max(alignof(CallableWrapperBase), alignof(CallableWrapperBase*))) u8 m_storage[inline_capacity];
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue