Support for cross compilation.
Refactor architecture specific files into arm and x86 name spaces. Make
assemblers and calling conventions use the factory pattern and an
instruction set specifier.
Change-Id: I20cd7aecacc1ae3d418221d98bbe1d69be9162a7
diff --git a/src/compiler.h b/src/compiler.h
index 1214d3c..e818a1c 100644
--- a/src/compiler.h
+++ b/src/compiler.h
@@ -3,13 +3,18 @@
#ifndef ART_SRC_COMPILER_H_
#define ART_SRC_COMPILER_H_
+#include "constants.h"
#include "dex_file.h"
+#include "jni_compiler.h"
#include "object.h"
namespace art {
class Compiler {
public:
+ explicit Compiler(InstructionSet insns) : instruction_set_(insns),
+ jni_compiler_(insns) {}
+
// Compile all Methods of all the Classes of all the DexFiles that are part of a ClassLoader.
void CompileAll(const ClassLoader* class_loader);
@@ -32,6 +37,11 @@
// method pointers of CodeAndDirectMethods entries in the DexCaches.
void SetCodeAndDirectMethods(const ClassLoader* class_loader);
void SetCodeAndDirectMethodsDexFile(const DexFile& dex_file);
+
+ InstructionSet instruction_set_;
+ JniCompiler jni_compiler_;
+
+ DISALLOW_COPY_AND_ASSIGN(Compiler);
};
} // namespace art