/bionic/tests/libs/ |
D | bionic_tests_zipalign.cpp | 68 static bool CreateAlignedZip(ZipArchiveHandle& handle, FILE* zip_dst, uint32_t alignment) { in CreateAlignedZip() argument 88 error = writer.StartAlignedEntry(zip_name.c_str(), flags, alignment); in CreateAlignedZip() 128 unsigned long int alignment = strtoul(argv[1], &end, 10); in main() local 129 if ((alignment == ULONG_MAX && errno == ERANGE) || *end != '\0') { in main() 134 if (((alignment - 1) & alignment) != 0) { in main() 154 bool success = CreateAlignedZip(handle, zip_dst, static_cast<uint32_t>(alignment)); in main()
|
/bionic/libc/private/ |
D | bionic_macros.h | 43 #define BIONIC_ALIGN(value, alignment) \ argument 44 (((value) + (alignment) - 1) & ~((alignment) - 1))
|
/bionic/libc/malloc_debug/ |
D | malloc_debug.cpp | 76 void* debug_memalign(size_t alignment, size_t bytes); 81 int debug_posix_memalign(void** memptr, size_t alignment, size_t size); 412 void* debug_memalign(size_t alignment, size_t bytes) { in debug_memalign() argument 414 return g_dispatch->memalign(alignment, bytes); in debug_memalign() 430 if (!powerof2(alignment)) { in debug_memalign() 431 alignment = BIONIC_ROUND_UP_POWER_OF_2(alignment); in debug_memalign() 435 if (alignment < MINIMUM_ALIGNMENT_BYTES) { in debug_memalign() 436 alignment = MINIMUM_ALIGNMENT_BYTES; in debug_memalign() 442 size_t real_size = alignment + bytes + g_debug->extra_bytes(); in debug_memalign() 456 value += (-value % alignment); in debug_memalign() [all …]
|
D | RecordData.cpp | 90 MemalignEntry::MemalignEntry(void* pointer, size_t size, size_t alignment) in MemalignEntry() argument 91 : MallocEntry(pointer, size), alignment_(alignment) { in MemalignEntry()
|
D | RecordData.h | 135 MemalignEntry(void* pointer, size_t size, size_t alignment);
|
D | README.md | 292 pointer = memalign(alignment, size) 294 **THREAD\_ID**: memalign pointer alignment size 296 posix\_memalign(&pointer, alignment, size) 298 **THREAD\_ID**: memalign pointer alignment size
|
/bionic/tests/ |
D | malloc_test.cpp | 79 for (size_t alignment = 1 << i; alignment < (1U << (i+1)); alignment++) { in TEST() local 80 char *ptr = reinterpret_cast<char*>(memalign(alignment, 100)); in TEST() 81 ASSERT_TRUE(ptr != NULL) << "Failed at alignment " << alignment; in TEST() 82 ASSERT_LE(100U, malloc_usable_size(ptr)) << "Failed at alignment " << alignment; in TEST() 84 << "Failed at alignment " << alignment; in TEST() 115 for (size_t alignment = 1; alignment <= 4096; alignment <<= 1) { in TEST() local 116 char *ptr = (char*)memalign(alignment, 100); in TEST() 119 ASSERT_EQ(0U, (intptr_t)ptr % alignment); in TEST()
|
D | buffer_tests.cpp | 195 static void *GetAlignedPtr(void *orig_ptr, int alignment, int or_mask) { in GetAlignedPtr() argument 197 if (alignment > 0) { in GetAlignedPtr() 201 ptr += alignment - (ptr & (alignment - 1)); in GetAlignedPtr() 202 ptr |= alignment | or_mask; in GetAlignedPtr()
|
D | pthread_test.cpp | 1782 void* allocate(size_t size, size_t alignment) { in allocate() argument 1783 char* p = new char[size + alignment * 2]; in allocate() 1785 while (!is_strict_aligned(p, alignment)) { in allocate() 1798 bool is_strict_aligned(char* p, size_t alignment) { in is_strict_aligned() argument 1799 return (reinterpret_cast<uintptr_t>(p) % (alignment * 2)) == alignment; in is_strict_aligned()
|
/bionic/libc/bionic/ |
D | malloc_common.cpp | 129 extern "C" void* memalign(size_t alignment, size_t bytes) { in memalign() argument 132 return _memalign(alignment, bytes); in memalign() 134 return Malloc(memalign)(alignment, bytes); in memalign() 137 extern "C" int posix_memalign(void** memptr, size_t alignment, size_t size) { in posix_memalign() argument 140 return _posix_memalign(memptr, alignment, size); in posix_memalign() 142 return Malloc(posix_memalign)(memptr, alignment, size); in posix_memalign()
|
/bionic/libc/include/ |
D | malloc.h | 42 void* memalign(size_t alignment, size_t byte_count) __mallocfunc __BIONIC_ALLOC_SIZE(2) __wur;
|
D | stdlib.h | 75 int posix_memalign(void** memptr, size_t alignment, size_t size) __INTRODUCED_IN(16);
|
/bionic/libc/kernel/uapi/mtd/ |
D | ubi-user.h | 71 __s32 alignment; member
|
/bionic/libc/malloc_debug/tests/ |
D | malloc_debug_unit_tests.cpp | 324 for (size_t alignment = 1; alignment <= 256; alignment++) { in TEST_F() local 325 pointer = reinterpret_cast<uint8_t*>(debug_memalign(alignment, 100)); in TEST_F() 328 size_t alignment_mask = alignment - 1; in TEST_F() 329 if (!powerof2(alignment)) { in TEST_F() 330 alignment_mask = BIONIC_ROUND_UP_POWER_OF_2(alignment) - 1; in TEST_F() 416 for (size_t alignment = 1; alignment <= 256; alignment++) { in TEST_F() local 417 pointer = reinterpret_cast<uint8_t*>(debug_memalign(alignment, 100)); in TEST_F() 421 size_t alignment_mask = alignment - 1; in TEST_F() 422 if (!powerof2(alignment)) { in TEST_F() 423 alignment_mask = BIONIC_ROUND_UP_POWER_OF_2(alignment) - 1; in TEST_F() [all …]
|
/bionic/libc/kernel/uapi/drm/ |
D | i915_drm.h | 374 int alignment; member 490 __u64 alignment; member 511 __u64 alignment; member 582 __u64 alignment; member
|
D | radeon_drm.h | 695 int alignment; member 762 __u64 alignment; member
|
D | amdgpu_drm.h | 75 __u64 alignment; member
|
/bionic/linker/ |
D | linker_phdr.h | 68 bool CheckFileRange(ElfW(Addr) offset, size_t size, size_t alignment);
|
D | linker_phdr.cpp | 277 bool ElfReader::CheckFileRange(ElfW(Addr) offset, size_t size, size_t alignment) { in CheckFileRange() argument 290 ((offset % alignment) == 0); in CheckFileRange()
|
/bionic/ |
D | android-changes-for-ndk-developers.md | 112 Current versions of the zipalign tool take care of alignment.
|