Lines Matching refs:alignment
107 void* FrameHeap::Alloc( u32 size, int alignment ) in Alloc() argument
114 NW_ASSERT( alignment % MIN_ALIGNMENT == 0 ); in Alloc()
115 NW_ASSERT( (Abs(alignment) & (Abs(alignment) - 1)) == 0 ); in Alloc()
116 NW_ASSERT( MIN_ALIGNMENT <= Abs(alignment) ); in Alloc()
127 if ( alignment >= 0 ) // ヒープ先頭から確保 in Alloc()
129 memory = AllocFromHead( size, alignment ); in Alloc()
133 memory = AllocFromTail( size, -alignment ); in Alloc()
154 void* FrameHeap::AllocFromHead( u32 size, int alignment ) in AllocFromHead() argument
156 void* newBlock = RoundUp( mHeadAllocator, (u32)alignment ); in AllocFromHead()
187 void* FrameHeap::AllocFromTail( u32 size, int alignment ) in AllocFromTail() argument
190 AddOffsetToPtr( mTailAllocator, -static_cast<s32>(size) ), static_cast<u32>(alignment) ); in AllocFromTail()
291 u32 FrameHeap::GetAllocatableSize( int alignment ) in GetAllocatableSize() argument
295 NW_ASSERT( alignment % MIN_ALIGNMENT == 0 ); in GetAllocatableSize()
296 NW_ASSERT( (Abs( alignment ) & (Abs( alignment ) - 1)) == 0 ); in GetAllocatableSize()
297 NW_ASSERT( MIN_ALIGNMENT <= Abs( alignment ) ); in GetAllocatableSize()
299 alignment = Abs( alignment ); in GetAllocatableSize()
306 const void* block = RoundUp( mHeadAllocator, (u32)alignment ); in GetAllocatableSize()