diff options
Diffstat (limited to 'compiler/common_compiler_test.cc')
-rw-r--r-- | compiler/common_compiler_test.cc | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/compiler/common_compiler_test.cc b/compiler/common_compiler_test.cc index 4824763288..87197becf9 100644 --- a/compiler/common_compiler_test.cc +++ b/compiler/common_compiler_test.cc @@ -65,23 +65,17 @@ void CommonCompilerTest::MakeExecutable(ArtMethod* method) { ArrayRef<const uint8_t> vmap_table = compiled_method->GetVmapTable(); const uint32_t vmap_table_offset = vmap_table.empty() ? 0u : sizeof(OatQuickMethodHeader) + vmap_table.size(); - // The method info is directly before the vmap table. - ArrayRef<const uint8_t> method_info = compiled_method->GetMethodInfo(); - const uint32_t method_info_offset = method_info.empty() ? 0u - : vmap_table_offset + method_info.size(); - - OatQuickMethodHeader method_header(vmap_table_offset, method_info_offset, code_size); + OatQuickMethodHeader method_header(vmap_table_offset, code_size); header_code_and_maps_chunks_.push_back(std::vector<uint8_t>()); std::vector<uint8_t>* chunk = &header_code_and_maps_chunks_.back(); const size_t max_padding = GetInstructionSetAlignment(compiled_method->GetInstructionSet()); - const size_t size = method_info.size() + vmap_table.size() + sizeof(method_header) + code_size; + const size_t size = vmap_table.size() + sizeof(method_header) + code_size; chunk->reserve(size + max_padding); chunk->resize(sizeof(method_header)); static_assert(std::is_trivially_copyable<OatQuickMethodHeader>::value, "Cannot use memcpy"); memcpy(&(*chunk)[0], &method_header, sizeof(method_header)); chunk->insert(chunk->begin(), vmap_table.begin(), vmap_table.end()); - chunk->insert(chunk->begin(), method_info.begin(), method_info.end()); chunk->insert(chunk->end(), code.begin(), code.end()); CHECK_EQ(chunk->size(), size); const void* unaligned_code_ptr = chunk->data() + (size - code_size); |