Lines Matching refs:chunk
1671 for (const ImageChunk& chunk : chunks_) { in ValidateBootImageChecksum() local
1675 if (chunk.start_index != component_count) { in ValidateBootImageChecksum()
1678 if (chunk.component_count > boot_image_component_count - component_count) { in ValidateBootImageChecksum()
1684 component_count + chunk.component_count); in ValidateBootImageChecksum()
1687 component_count += chunk.component_count; in ValidateBootImageChecksum()
1688 composite_checksum ^= chunk.checksum; in ValidateBootImageChecksum()
1689 boot_image_size += chunk.reservation_size; in ValidateBootImageChecksum()
1856 ImageChunk chunk; in ReadHeader() local
1857 chunk.base_location = base_location; in ReadHeader()
1858 chunk.base_filename = base_filename; in ReadHeader()
1859 chunk.start_index = bcp_index; in ReadHeader()
1860 chunk.component_count = header.GetComponentCount(); in ReadHeader()
1861 chunk.image_space_count = header.GetImageSpaceCount(); in ReadHeader()
1862 chunk.reservation_size = header.GetImageReservationSize(); in ReadHeader()
1863 chunk.checksum = header.GetImageChecksum(); in ReadHeader()
1864 chunk.boot_image_component_count = header.GetBootImageComponentCount(); in ReadHeader()
1865 chunk.boot_image_checksum = header.GetBootImageChecksum(); in ReadHeader()
1866 chunk.boot_image_size = header.GetBootImageSize(); in ReadHeader()
1867 chunks_.push_back(std::move(chunk)); in ReadHeader()
2051 ImageChunk chunk; in CompileBootclasspathElements() local
2052 chunk.base_location = base_location; in CompileBootclasspathElements()
2053 chunk.base_filename = base_filename; in CompileBootclasspathElements()
2054 chunk.profile_files = profile_filenames; in CompileBootclasspathElements()
2055 chunk.start_index = bcp_index; in CompileBootclasspathElements()
2056 chunk.component_count = header.GetComponentCount(); in CompileBootclasspathElements()
2057 chunk.image_space_count = header.GetImageSpaceCount(); in CompileBootclasspathElements()
2058 chunk.reservation_size = header.GetImageReservationSize(); in CompileBootclasspathElements()
2059 chunk.checksum = header.GetImageChecksum(); in CompileBootclasspathElements()
2060 chunk.boot_image_component_count = header.GetBootImageComponentCount(); in CompileBootclasspathElements()
2061 chunk.boot_image_checksum = header.GetBootImageChecksum(); in CompileBootclasspathElements()
2062 chunk.boot_image_size = header.GetBootImageSize(); in CompileBootclasspathElements()
2063 chunk.art_fd.reset(art_fd.release()); in CompileBootclasspathElements()
2064 chunk.vdex_fd.reset(vdex_fd.release()); in CompileBootclasspathElements()
2065 chunk.oat_fd.reset(oat_fd.release()); in CompileBootclasspathElements()
2066 chunks_.push_back(std::move(chunk)); in CompileBootclasspathElements()
2312 const BootImageLayout::ImageChunk& chunk = chunks[i]; in LoadImage() local
2316 DCHECK_LE(chunk.reservation_size, old_reservation_size); in LoadImage()
2317 if (!LoadComponents(chunk, in LoadImage()
2329 size_t new_reservation_size = old_reservation_size - chunk.reservation_size; in LoadImage()
2347 boot_class_path_locations_[chunk.start_index].c_str(), in LoadImage()
2357 << boot_class_path_locations_[chunk.start_index] << ": " << extension_error_msg; in LoadImage()
2365 if (max_image_space_dependencies == chunk.start_index && in LoadImage()
2366 total_component_count == chunk.start_index + chunk.component_count) { in LoadImage()
2367 max_image_space_dependencies = chunk.start_index + chunk.component_count; in LoadImage()
3000 bool LoadComponents(const BootImageLayout::ImageChunk& chunk, in LoadComponents() argument
3028 bool is_extension = (chunk.start_index != 0u); in LoadComponents()
3030 if (max_image_space_dependencies < chunk.boot_image_component_count) { in LoadComponents()
3033 boot_class_path_locations_[chunk.start_index].c_str(), in LoadComponents()
3035 chunk.boot_image_component_count); in LoadComponents()
3040 chunk.start_index, chunk.image_space_count); in LoadComponents()
3042 ExpandMultiImageLocations(requested_bcp_locations, chunk.base_location, is_extension); in LoadComponents()
3044 ExpandMultiImageLocations(requested_bcp_locations, chunk.base_filename, is_extension); in LoadComponents()
3049 if (chunk.art_fd.get() >= 0) { in LoadComponents()
3051 image_fd = std::move(chunk.art_fd); in LoadComponents()
3053 size_t pos = chunk.start_index + i; in LoadComponents()
3062 chunk.profile_files, in LoadComponents()
3071 uint32_t expected_component_count = (i == 0u) ? chunk.component_count : 0u; in LoadComponents()
3072 uint32_t expected_reservation_size = (i == 0u) ? chunk.reservation_size : 0u; in LoadComponents()
3078 if (i == 0 && (chunk.checksum != header.GetImageChecksum() || in LoadComponents()
3079 chunk.image_space_count != header.GetImageSpaceCount() || in LoadComponents()
3080 chunk.boot_image_component_count != header.GetBootImageComponentCount() || in LoadComponents()
3081 chunk.boot_image_checksum != header.GetBootImageChecksum() || in LoadComponents()
3082 chunk.boot_image_size != header.GetBootImageSize())) { in LoadComponents()
3090 chunk.checksum, in LoadComponents()
3091 chunk.image_space_count, in LoadComponents()
3094 chunk.boot_image_component_count, in LoadComponents()
3096 chunk.boot_image_checksum, in LoadComponents()
3098 chunk.boot_image_size, in LoadComponents()
3103 DCHECK_GE(max_image_space_dependencies, chunk.boot_image_component_count); in LoadComponents()
3106 while (dependency_component_count < chunk.boot_image_component_count && in LoadComponents()
3112 if (dependency_component_count != chunk.boot_image_component_count) { in LoadComponents()
3115 chunk.boot_image_component_count); in LoadComponents()
3122 ImageSpace* space = (*spaces)[spaces->size() - chunk.image_space_count + i].get(); in LoadComponents()
3123 size_t bcp_chunk_size = (chunk.image_space_count == 1u) ? chunk.component_count : 1u; in LoadComponents()
3125 size_t pos = chunk.start_index + i; in LoadComponents()
3134 if (chunk.vdex_fd.get() >= 0) { in LoadComponents()
3136 vdex_fd = std::move(chunk.vdex_fd); in LoadComponents()
3144 if (chunk.oat_fd.get() >= 0) { in LoadComponents()
3146 oat_fd = std::move(chunk.oat_fd); in LoadComponents()