diff options
author | Andreas Gampe <agampe@google.com> | 2015-01-22 20:39:27 -0800 |
---|---|---|
committer | Andreas Gampe <agampe@google.com> | 2015-01-26 14:30:40 -0800 |
commit | 0b9203e7996ee1856f620f95d95d8a273c43a3df (patch) | |
tree | a9715986cfdbb21e4d64f72b56fac255cc8b9309 /compiler/dex/mir_graph.h | |
parent | 4dfe58d8f2d398963f31831a57fbd12e282e1196 (diff) | |
download | art-0b9203e7996ee1856f620f95d95d8a273c43a3df.tar.gz art-0b9203e7996ee1856f620f95d95d8a273c43a3df.tar.bz2 art-0b9203e7996ee1856f620f95d95d8a273c43a3df.zip |
ART: Some Quick cleanup
Make several fields const in CompilationUnit. May benefit some Mir2Lir
code that repeats tests, and in general immutability is good.
Remove compiler_internals.h and refactor some other headers to reduce
overly broad imports (and thus forced recompiles on changes).
Change-Id: I898405907c68923581373b5981d8a85d2e5d185a
Diffstat (limited to 'compiler/dex/mir_graph.h')
-rw-r--r-- | compiler/dex/mir_graph.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/compiler/dex/mir_graph.h b/compiler/dex/mir_graph.h index af97f51975..5def19128c 100644 --- a/compiler/dex/mir_graph.h +++ b/compiler/dex/mir_graph.h @@ -19,10 +19,9 @@ #include <stdint.h> -#include "compiler_ir.h" #include "dex_file.h" #include "dex_instruction.h" -#include "driver/dex_compilation_unit.h" +#include "dex_types.h" #include "invoke_type.h" #include "mir_field_info.h" #include "mir_method_info.h" @@ -34,9 +33,14 @@ namespace art { +struct CompilationUnit; +class DexCompilationUnit; class DexFileMethodInliner; class GlobalValueNumbering; +// Forward declaration. +class MIRGraph; + enum DataFlowAttributePos { kUA = 0, kUB, @@ -139,7 +143,6 @@ enum OatMethodAttributes { // Minimum field size to contain Dalvik v_reg number. #define VREG_NUM_WIDTH 16 -#define INVALID_SREG (-1) #define INVALID_VREG (0xFFFFU) #define INVALID_OFFSET (0xDEADF00FU) @@ -553,9 +556,7 @@ class MIRGraph { * This is guaranteed to contain index 0 which is the base method being compiled. * @return Returns the raw instruction pointer. */ - const uint16_t* GetInsns(int m_unit_index) const { - return m_units_[m_unit_index]->GetCodeItem()->insns_; - } + const uint16_t* GetInsns(int m_unit_index) const; /** * @brief Used to obtain the raw data table. |