summaryrefslogtreecommitdiffstats
path: root/compiler/dex/dex_to_dex_compiler.cc
diff options
context:
space:
mode:
authorAndreas Gampe <agampe@google.com>2018-12-28 09:39:56 -0800
committerAndreas Gampe <agampe@google.com>2019-01-02 10:32:25 -0800
commit3f1dcd39e134d994ac88dcc4f30ec8cabcd8decf (patch)
tree365d20ad6b68ff1dbd4903764b63880324136e4d /compiler/dex/dex_to_dex_compiler.cc
parent0f0a4e40667c87fbd4ae5480eddbfd701bfabfa2 (diff)
downloadart-3f1dcd39e134d994ac88dcc4f30ec8cabcd8decf.tar.gz
art-3f1dcd39e134d994ac88dcc4f30ec8cabcd8decf.tar.bz2
art-3f1dcd39e134d994ac88dcc4f30ec8cabcd8decf.zip
ART: Move dex structs into own header
Separating out the structs from DexFile allows them to be forward- declared, which reduces the need to include the dex_file header. Bug: 119869270 Test: m Change-Id: I32dde5a632884bca7435cd584b4a81883de2e7b4
Diffstat (limited to 'compiler/dex/dex_to_dex_compiler.cc')
-rw-r--r--compiler/dex/dex_to_dex_compiler.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/dex/dex_to_dex_compiler.cc b/compiler/dex/dex_to_dex_compiler.cc
index cf52dd9cf3..23ce37ef1a 100644
--- a/compiler/dex/dex_to_dex_compiler.cc
+++ b/compiler/dex/dex_to_dex_compiler.cc
@@ -505,7 +505,7 @@ void DexToDexCompiler::CompilationState::CompileInvokeVirtual(Instruction* inst,
}
CompiledMethod* DexToDexCompiler::CompileMethod(
- const DexFile::CodeItem* code_item,
+ const dex::CodeItem* code_item,
uint32_t access_flags,
InvokeType invoke_type ATTRIBUTE_UNUSED,
uint16_t class_def_idx,
@@ -627,11 +627,11 @@ CompiledMethod* DexToDexCompiler::CompileMethod(
void DexToDexCompiler::SetDexFiles(const std::vector<const DexFile*>& dex_files) {
// Record what code items are already seen to detect when multiple methods have the same code
// item.
- std::unordered_set<const DexFile::CodeItem*> seen_code_items;
+ std::unordered_set<const dex::CodeItem*> seen_code_items;
for (const DexFile* dex_file : dex_files) {
for (ClassAccessor accessor : dex_file->GetClasses()) {
for (const ClassAccessor::Method& method : accessor.GetMethods()) {
- const DexFile::CodeItem* code_item = method.GetCodeItem();
+ const dex::CodeItem* code_item = method.GetCodeItem();
// Detect the shared code items.
if (!seen_code_items.insert(code_item).second) {
shared_code_items_.insert(code_item);
@@ -646,7 +646,7 @@ void DexToDexCompiler::UnquickenConflictingMethods() {
MutexLock mu(Thread::Current(), lock_);
size_t unquicken_count = 0;
for (const auto& pair : shared_code_item_quicken_info_) {
- const DexFile::CodeItem* code_item = pair.first;
+ const dex::CodeItem* code_item = pair.first;
const QuickenState& state = pair.second;
CHECK_GE(state.methods_.size(), 1u);
if (state.conflict_) {