Searched refs:AlignTo (Results 1 – 9 of 9) sorted by relevance
/system/core/fs_mgr/liblp/ |
D | utility_test.cpp | 63 std::optional<uint64_t> AlignTo(uint64_t base, uint32_t alignment) { in AlignTo() function 65 if (!AlignTo(base, alignment, &r)) { in AlignTo() 71 TEST(liblp, AlignTo) { in TEST() argument 72 EXPECT_EQ(AlignTo(37, 0), std::optional<uint64_t>(37)); in TEST() 73 EXPECT_EQ(AlignTo(1024, 1024), std::optional<uint64_t>(1024)); in TEST() 74 EXPECT_EQ(AlignTo(555, 1024), std::optional<uint64_t>(1024)); in TEST() 75 EXPECT_EQ(AlignTo(555, 1000), std::optional<uint64_t>(1000)); in TEST() 76 EXPECT_EQ(AlignTo(0, 1024), std::optional<uint64_t>(0)); in TEST() 77 EXPECT_EQ(AlignTo(54, 32), std::optional<uint64_t>(64)); in TEST() 78 EXPECT_EQ(AlignTo(32, 32), std::optional<uint64_t>(32)); in TEST() [all …]
|
D | utility.h | 72 bool AlignTo(T base, uint32_t alignment, T* out) { in AlignTo() function
|
D | builder.cpp | 406 if (!AlignTo(metadata_max_size, LP_SECTOR_SIZE, &metadata_max_size)) { in Init() 443 ok = AlignTo(free_area_start, out.alignment, &free_area_start); in Init() 445 ok = AlignTo(free_area_start, logical_block_size, &free_area_start); in Init() 488 ok = AlignTo(free_area_start, super.alignment, &free_area_start); in Init() 490 ok = AlignTo(free_area_start, logical_block_size, &free_area_start); in Init() 991 if (!AlignTo(lba, block_device.alignment, out)) { in AlignSector() 994 if (!AlignTo(*out, LP_SECTOR_SIZE, out)) { in AlignSector() 1073 if (!AlignTo(requested_size, geometry_.logical_block_size, &aligned_size)) { in ResizePartition()
|
D | super_layout_builder.cpp | 138 if (!AlignTo(metadata_bytes.size(), kSparseAlignment, &metadata_aligned_bytes)) { in GetImageLayout()
|
D | builder_test.cpp | 235 ASSERT_TRUE(AlignTo(lba, device_info.alignment, &aligned_lba)); in TEST_F()
|
/system/tools/aidl/ |
D | aidl_to_cpp_common.cpp | 570 size_t AlignTo(size_t val, size_t align) { in AlignTo() function 593 size_t tag_size = AlignTo(1, *align); in SizeOfDefinedType() 595 return AlignTo(size, *align) + tag_size; in SizeOfDefinedType() 605 res = AlignTo(res, *alignment); in SizeOfDefinedType() 615 res = AlignTo(res, *parcelable_alignment); in SizeOfDefinedType()
|
D | aidl_to_cpp_common.h | 54 size_t AlignTo(size_t val, size_t align);
|
D | generate_rust.cpp | 954 auto padding_size = cpp::AlignTo(struct_size, 8) - struct_size; in GeneratePaddingField() 997 struct_size = cpp::AlignTo(struct_size, *alignment); in GenerateParcelBody() 1017 variable_offset = cpp::AlignTo(variable_offset, *alignment); in GenerateParcelBody() 1073 struct_size = cpp::AlignTo(struct_size, *alignment); in GenerateParcelDefault()
|
D | generate_ndk.cpp | 1318 variable_offset = cpp::AlignTo(variable_offset, *alignment); in GenerateParcelClassDecl()
|