Quick compiler: Single .so for all targets

With this CL, all targets can be built into a single .so (but
we're not yet doing so - the compiler driver needs to be reworked).

A new Codgen class is introduced (see compiler/codegen/codegen.h),
along with target-specific sub-classes ArmCodegen, MipsCodegens and
X86Codegen (see compiler/codegen/*/codegen_[Arm|Mips|X86].h).

Additional minor code, comment and format refactoring.  Some source
files combined, temporary header files deleted and a few file
renames to better identify their function.

Next up is combining the Quick and Portable .so files.

Note: building all targets into libdvm-compiler.so increases its
size by 140K bytes.  I'm inclined to not bother introducing conditional
compilation to limit code to the specific target - the added build and
testing complexity doesn't doesn't seem worth such a modest size savings.

Change-Id: Id9c5b4502ad6b77cdb31f71d3126f51a4f2e9dfe
diff --git a/build/Android.libart-compiler.mk b/build/Android.libart-compiler.mk
index c940a42..3d12527 100644
--- a/build/Android.libart-compiler.mk
+++ b/build/Android.libart-compiler.mk
@@ -17,7 +17,6 @@
 LIBART_COMPILER_COMMON_SRC_FILES += \
 	src/compiler/dataflow.cc \
 	src/compiler/frontend.cc \
-	src/compiler/intermediate_rep.cc \
 	src/compiler/ralloc.cc \
 	src/compiler/ssa_transformation.cc \
 	src/compiler/compiler_utility.cc \
@@ -26,8 +25,8 @@
 	src/compiler/codegen/gen_loadstore.cc \
 	src/compiler/codegen/gen_common.cc \
 	src/compiler/codegen/gen_invoke.cc \
-	src/compiler/codegen/method_bitcode.cc \
-	src/compiler/codegen/method_codegen_driver.cc \
+	src/compiler/codegen/mir_to_gbc.cc \
+	src/compiler/codegen/mir_to_lir.cc \
 	src/compiler/codegen/local_optimizations.cc \
 	src/oat/jni/calling_convention.cc \
 	src/oat/jni/jni_compiler.cc \
@@ -35,37 +34,37 @@
 	src/oat/jni/mips/calling_convention_mips.cc \
 	src/oat/jni/x86/calling_convention_x86.cc \
 	src/greenland/ir_builder.cc \
-	src/greenland/intrinsic_helper.cc
-
-LIBART_COMPILER_arm_SRC_FILES += \
-	$(LIBART_COMPILER_COMMON_SRC_FILES) \
+	src/greenland/intrinsic_helper.cc \
 	src/compiler/codegen/arm/target_arm.cc \
 	src/compiler/codegen/arm/assemble_arm.cc \
 	src/compiler/codegen/arm/utility_arm.cc \
 	src/compiler/codegen/arm/call_arm.cc \
 	src/compiler/codegen/arm/fp_arm.cc \
 	src/compiler/codegen/arm/int_arm.cc \
-	src/oat/jni/arm/jni_internal_arm.cc
-
-LIBART_COMPILER_mips_SRC_FILES += \
-	$(LIBART_COMPILER_COMMON_SRC_FILES) \
 	src/compiler/codegen/mips/target_mips.cc \
 	src/compiler/codegen/mips/assemble_mips.cc \
 	src/compiler/codegen/mips/utility_mips.cc \
 	src/compiler/codegen/mips/call_mips.cc \
 	src/compiler/codegen/mips/fp_mips.cc \
 	src/compiler/codegen/mips/int_mips.cc \
-	src/oat/jni/mips/jni_internal_mips.cc
-
-LIBART_COMPILER_x86_SRC_FILES += \
-	$(LIBART_COMPILER_COMMON_SRC_FILES) \
 	src/compiler/codegen/x86/target_x86.cc \
 	src/compiler/codegen/x86/assemble_x86.cc \
 	src/compiler/codegen/x86/utility_x86.cc \
 	src/compiler/codegen/x86/call_x86.cc \
 	src/compiler/codegen/x86/fp_x86.cc \
 	src/compiler/codegen/x86/int_x86.cc \
-	src/oat/jni/x86/jni_internal_x86.cc
+	src/oat/jni/arm/jni_internal_arm.cc \
+	src/oat/jni/mips/jni_internal_mips.cc \
+	src/oat/jni/x86/jni_internal_x86.cc \
+
+LIBART_COMPILER_arm_SRC_FILES += \
+	$(LIBART_COMPILER_COMMON_SRC_FILES)
+
+LIBART_COMPILER_mips_SRC_FILES += \
+	$(LIBART_COMPILER_COMMON_SRC_FILES)
+
+LIBART_COMPILER_x86_SRC_FILES += \
+	$(LIBART_COMPILER_COMMON_SRC_FILES)
 
 # $(1): target or host
 # $(2): ndebug or debug