Added option to allow verification of objects on the stack.

Currently it's defined out by VERIFY_OBJECT_ENABLED. Also made various
fixes to allow heap object verification to work again.

(cherry picked from commit d4983495782be8d54c9c1f0266dc52395b947724)

Change-Id: Icd625e1e0dc240c0ad1d10e2c58c7d5d63fec030
diff --git a/src/thread.h b/src/thread.h
index c35d26a..d764ff3 100644
--- a/src/thread.h
+++ b/src/thread.h
@@ -324,6 +324,12 @@
 
   void VisitRoots(Heap::RootVisitor* visitor, void* arg);
 
+#if VERIFY_OBJECT_ENABLED
+  void VerifyStack();
+#else
+  void VerifyStack() {}
+#endif
+
   //
   // Offsets of various members of native Thread class, used by compiled code.
   //