#include <stddef.h>
#include "src/__support/CPP/array.h"
#include "src/__support/CPP/bit.h"
#include "src/__support/CPP/span.h"
#include "src/__support/block.h"
#include "src/string/memcpy.h"
#include "test/UnitTest/Test.h"
LargeOffsetBlock;
SmallOffsetBlock;
#define TEST_FOR_EACH_BLOCK_TYPE(TestCase) …
array;
bit_ceil;
byte;
span;
TEST_FOR_EACH_BLOCK_TYPE(CanCreateSingleAlignedBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanCreateUnalignedSingleBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotCreateTooSmallBlock) { … }
TEST(LlvmLibcBlockTest, CannotCreateTooLargeBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanSplitBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanSplitBlockUnaligned) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanSplitMidBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotSplitTooSmallBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotSplitBlockWithoutHeaderSpace) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotMakeBlockLargerInSplit) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotMakeSecondBlockLargerInSplit) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotMakeZeroSizeFirstBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanMakeMinimalSizeFirstBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanMakeMinimalSizeSecondBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanMarkBlockUsed) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotSplitUsedBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanMergeWithNextBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotMergeWithFirstOrLastBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CannotMergeUsedBlock) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanGetBlockFromUsableSpace) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanGetConstBlockFromUsableSpace) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanAllocate) { … }
TEST_FOR_EACH_BLOCK_TYPE(AllocateAlreadyAligned) { … }
TEST_FOR_EACH_BLOCK_TYPE(AllocateNeedsAlignment) { … }
TEST_FOR_EACH_BLOCK_TYPE(PreviousBlockMergedIfNotFirst) { … }
TEST_FOR_EACH_BLOCK_TYPE(CanRemergeBlockAllocations) { … }