Lines Matching refs:alignment
85 void *Allocate(const StackTrace &stack, uptr size, uptr alignment, in Allocate() argument
91 void *p = allocator.Allocate(GetAllocatorCache(), size, alignment); in Allocate()
125 uptr alignment) { in Reallocate() argument
132 allocator.Reallocate(GetAllocatorCache(), p, new_size, alignment); in Reallocate()
151 int lsan_posix_memalign(void **memptr, uptr alignment, uptr size, in lsan_posix_memalign() argument
153 if (UNLIKELY(!CheckPosixMemalignAlignment(alignment))) { in lsan_posix_memalign()
156 ReportInvalidPosixMemalignAlignment(alignment, &stack); in lsan_posix_memalign()
158 void *ptr = Allocate(stack, size, alignment, kAlwaysClearMemory); in lsan_posix_memalign()
162 CHECK(IsAligned((uptr)ptr, alignment)); in lsan_posix_memalign()
167 void *lsan_aligned_alloc(uptr alignment, uptr size, const StackTrace &stack) { in lsan_aligned_alloc() argument
168 if (UNLIKELY(!CheckAlignedAllocAlignmentAndSize(alignment, size))) { in lsan_aligned_alloc()
172 ReportInvalidAlignedAllocAlignment(size, alignment, &stack); in lsan_aligned_alloc()
174 return SetErrnoOnNull(Allocate(stack, size, alignment, kAlwaysClearMemory)); in lsan_aligned_alloc()
177 void *lsan_memalign(uptr alignment, uptr size, const StackTrace &stack) { in lsan_memalign() argument
178 if (UNLIKELY(!IsPowerOfTwo(alignment))) { in lsan_memalign()
182 ReportInvalidAllocationAlignment(alignment, &stack); in lsan_memalign()
184 return SetErrnoOnNull(Allocate(stack, size, alignment, kAlwaysClearMemory)); in lsan_memalign()