Support for promoting Method* and compiler temps

This CL completes the support for allowing compiler-generated
data to be treated as a Dalvik register and become subject to
the normal register promotion and live temp tracking machinery.

Also:
   o Removes some vestigal and useless Method* loads from
     range argument setup.
   o Changes the Method* pseudo vReg number from -1 to -2 to
     avoid a conflict with the 0xffff marker in the register map.
   o Removes some experimental code for CSE at the basic block
     level.

Change-Id: I112a8bbe20f95a8d789f63908c84e5fa167c74ac
diff --git a/src/compiler/Ralloc.cc b/src/compiler/Ralloc.cc
index b170d81..872adae 100644
--- a/src/compiler/Ralloc.cc
+++ b/src/compiler/Ralloc.cc
@@ -323,21 +323,21 @@
 
     /* Patch up the locations for Method* and the compiler temps */
     loc[cUnit->methodSReg].location = kLocCompilerTemp;
+    loc[cUnit->methodSReg].defined = true;
     for (i = 0; i < cUnit->numCompilerTemps; i++) {
         CompilerTemp* ct = (CompilerTemp*)cUnit->compilerTemps.elemList[i];
         loc[ct->sReg].location = kLocCompilerTemp;
+        loc[ct->sReg].defined = true;
     }
 
     cUnit->regLocation = loc;
 
     /* Allocation the promotion map */
     int numRegs = cUnit->numDalvikRegisters;
-    PromotionMap* tMap =
+    cUnit->promotionMap =
         (PromotionMap*)oatNew(cUnit, (numRegs + cUnit->numCompilerTemps + 1) *
                               sizeof(cUnit->promotionMap[0]), true,
                               kAllocRegAlloc);
-    // Bias the promotion map
-    cUnit->promotionMap = &tMap[cUnit->numCompilerTemps + 1];
 
     /* Add types of incoming arguments based on signature */
     int numIns = cUnit->numIns;