diff options
Diffstat (limited to 'src/compiler_llvm/compiler_llvm.h')
-rw-r--r-- | src/compiler_llvm/compiler_llvm.h | 47 |
1 files changed, 9 insertions, 38 deletions
diff --git a/src/compiler_llvm/compiler_llvm.h b/src/compiler_llvm/compiler_llvm.h index 7cc4a0e42d..24a766e2f4 100644 --- a/src/compiler_llvm/compiler_llvm.h +++ b/src/compiler_llvm/compiler_llvm.h @@ -19,10 +19,10 @@ #include "compiler.h" #include "dex_file.h" -#include "elf_image.h" #include "instruction_set.h" #include "macros.h" #include "object.h" +#include "procedure_linkage_table.h" #include <UniquePtr.h> @@ -54,7 +54,6 @@ namespace art { namespace compiler_llvm { class CompilationUnit; -class ElfLoader; class IRBuilder; class CompilerLLVM { @@ -63,10 +62,6 @@ class CompilerLLVM { ~CompilerLLVM(); - void MaterializeIfThresholdReached(); - - void MaterializeRemainder(); - Compiler* GetCompiler() const { return compiler_; } @@ -75,31 +70,10 @@ class CompilerLLVM { return insn_set_; } - size_t GetNumCompilationUnits() const { - return cunits_.size(); - } - - const CompilationUnit* GetCompilationUnit(size_t i) const { - return cunits_[i]; - } - void SetBitcodeFileName(std::string const& filename) { bitcode_filename_ = filename; } - void EnableAutoElfLoading(); - - bool IsAutoElfLoadingEnabled() const { - return (elf_loader_.get() != NULL); - } - - const void* GetMethodCodeAddr(const CompiledMethod* cm) const; - - const Method::InvokeStub* GetMethodInvokeStubAddr( - const CompiledInvokeStub* cm) const; - - std::vector<ElfImage> GetElfImages() const; - CompiledMethod* CompileDexMethod(OatCompilationUnit* oat_compilation_unit); CompiledMethod* CompileNativeMethod(OatCompilationUnit* oat_compilation_unit); @@ -108,32 +82,29 @@ class CompilerLLVM { CompiledInvokeStub* CreateProxyStub(const char *shorty); + const ProcedureLinkageTable& GetProcedureLinkageTable() const { + return plt_; + } + private: - void EnsureCompilationUnit(); + CompilationUnit* AllocateCompilationUnit(); void Materialize(CompilationUnit* cunit); - void LoadElfFromCompilationUnit(const CompilationUnit* cunit); - bool IsBitcodeFileNameAvailable() const { return !bitcode_filename_.empty(); } Compiler* compiler_; - public: - Mutex compiler_lock_; - - private: InstructionSet insn_set_; - CompilationUnit* curr_cunit_; - - std::vector<CompilationUnit*> cunits_; + Mutex num_cunits_lock_; + size_t num_cunits_; std::string bitcode_filename_; - UniquePtr<ElfLoader> elf_loader_; + ProcedureLinkageTable plt_; DISALLOW_COPY_AND_ASSIGN(CompilerLLVM); }; |