Use accessor methods for Object fields.

Ensure that Object fields are modified via accessors so that it's easy
to insert barriers (make all fields within Objects private). Add validity
checks to Field and Method accessors to ensure they are accessed when a
Class is in a suitable state. Add validity checks to all Object
accessors to check heap isn't corrupted. Remove hacked in strings from Field
and Method; make type fields used the dex cache that is lazily initialized.
Clean up various other TODOs and lint issues.

Change-Id: Iac0afc515c01f5419874d9cdcdb9a7b45443e3fb
diff --git a/src/compiler/Frontend.cc b/src/compiler/Frontend.cc
index 9ef2b4f..dbd06ab 100644
--- a/src/compiler/Frontend.cc
+++ b/src/compiler/Frontend.cc
@@ -733,7 +733,7 @@
     const art::DexFile& dex_file = class_linker->FindDexFile(
          method->GetDeclaringClass()->GetDexCache());
     const art::DexFile::CodeItem* code_item =
-         dex_file.GetCodeItem(method->code_off_);
+         dex_file.GetCodeItem(method->GetCodeItemOffset());
     const u2* codePtr = code_item->insns_;
     const u2* codeEnd = code_item->insns_ + code_item->insns_size_;
     int numBlocks = 0;
@@ -878,7 +878,7 @@
     }
 
     /* Adjust this value accordingly once inlining is performed */
-    cUnit.numDalvikRegisters = cUnit.method->num_registers_;
+    cUnit.numDalvikRegisters = cUnit.method->NumRegisters();
 
 
     /* Verify if all blocks are connected as claimed */