Use the UNIMPLEMENTED macro everywhere.

As suggested in review.

Change-Id: Ic14c91a622b545b4800ef021dfb501fb09cbda9d
diff --git a/src/assembler.cc b/src/assembler.cc
index 62f11a3..193d73f 100644
--- a/src/assembler.cc
+++ b/src/assembler.cc
@@ -117,22 +117,4 @@
   CHECK_EQ(Size(), old_size);
 }
 
-
-#if 0
-// Shared macros are implemented here.
-void Assembler::Unimplemented(const char* message) {
-  Stop("unimplemented");
-}
-
-
-void Assembler::Untested(const char* message) {
-  Stop("untested");
-}
-
-
-void Assembler::Unreachable(const char* message) {
-  Stop("unreachable");
-}
-#endif
-
 }  // namespace art
diff --git a/src/assembler_arm.cc b/src/assembler_arm.cc
index 70dd20c..b75263a 100644
--- a/src/assembler_arm.cc
+++ b/src/assembler_arm.cc
@@ -1508,7 +1508,7 @@
       mov(dest.AsCoreRegister(), ShifterOperand(src.AsCoreRegister()));
     } else {
       // TODO: VFP
-      LOG(FATAL) << "Unimplemented";
+      UNIMPLEMENTED(FATAL) << ": VFP";
     }
   }
 }
diff --git a/src/assembler_arm.h b/src/assembler_arm.h
index 04671db..f82107c 100644
--- a/src/assembler_arm.h
+++ b/src/assembler_arm.h
@@ -408,12 +408,6 @@
   static uint32_t DecodeUint32FromTstInstructions(uword pc);
   static bool IsInstructionForExceptionHandling(uword pc);
 
-  // Debugging and bringup support.
-  void Stop(const char* message);
-  void Unimplemented(const char* message);
-  void Untested(const char* message);
-  void Unreachable(const char* message);
-
   // Emit code that will create an activation on the stack
   void BuildFrame(size_t frame_size, ManagedRegister method_reg);
 
diff --git a/src/assembler_x86.cc b/src/assembler_x86.cc
index e377916..80896c5 100644
--- a/src/assembler_x86.cc
+++ b/src/assembler_x86.cc
@@ -1521,7 +1521,7 @@
       movl(dest.AsCpuRegister(), src.AsCpuRegister());
     } else {
       // TODO: x87, SSE
-      LOG(FATAL) << "Unimplemented";
+      UNIMPLEMENTED(FATAL) << ": x87, SSE";
     }
   }
 }
@@ -1608,7 +1608,7 @@
 
 void Assembler::Call(FrameOffset base, Offset offset,
                      ManagedRegister) {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
 }
 
 // Generate code to check if Thread::Current()->suspend_count_ is non-zero
diff --git a/src/assembler_x86.h b/src/assembler_x86.h
index ab010d1..400a304 100644
--- a/src/assembler_x86.h
+++ b/src/assembler_x86.h
@@ -507,9 +507,6 @@
 
   // Debugging and bringup support.
   void Stop(const char* message);
-  void Unimplemented(const char* message);
-  void Untested(const char* message);
-  void Unreachable(const char* message);
 
   static void InitializeMemoryWithBreakpoints(byte* data, size_t length);
 
diff --git a/src/calling_convention.cc b/src/calling_convention.cc
index ec8daeb..e21b317 100644
--- a/src/calling_convention.cc
+++ b/src/calling_convention.cc
@@ -15,7 +15,7 @@
 // Managed runtime calling convention
 
 size_t ManagedRuntimeCallingConvention::FrameSize() {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
   return 0;
 }
 
diff --git a/src/class_linker.cc b/src/class_linker.cc
index 4522378..4524457 100644
--- a/src/class_linker.cc
+++ b/src/class_linker.cc
@@ -865,7 +865,7 @@
   } else {
     // JValue unused;
     // TODO: dvmCallMethod(self, method, NULL, &unused);
-    //CHECK(!"unimplemented");
+    // UNIMPLEMENTED(FATAL);
   }
 
   {
diff --git a/src/dex_file.cc b/src/dex_file.cc
index 0645a65..da6ae9d 100644
--- a/src/dex_file.cc
+++ b/src/dex_file.cc
@@ -513,7 +513,7 @@
     case DexFile::kField:
     case DexFile::kArray:
     case DexFile::kAnnotation:
-      LOG(FATAL) << "Unimplemented";
+      UNIMPLEMENTED(FATAL) << ": type " << type;
       break;
     case DexFile::kNull:
       value->i = 0;
diff --git a/src/heap.cc b/src/heap.cc
index 86942fa..0746361 100644
--- a/src/heap.cc
+++ b/src/heap.cc
@@ -227,7 +227,7 @@
 // heap footprint to match the target utilization ratio.  This should
 // only be called immediately after a full garbage collection.
 void Heap::GrowForUtilization() {
-  LOG(ERROR) << "Unimplemented";
+  UNIMPLEMENTED(ERROR);
 }
 
 }  // namespace art
diff --git a/src/jni_internal.cc b/src/jni_internal.cc
index 55a9d71..6e6934f 100644
--- a/src/jni_internal.cc
+++ b/src/jni_internal.cc
@@ -13,8 +13,6 @@
 #include "stringpiece.h"
 #include "thread.h"
 
-#define UNIMPLEMENTED(LEVEL) LOG(LEVEL) << __FUNCTION__ << " unimplemented"
-
 namespace art {
 
 // Entry/exit processing for all JNI calls.
diff --git a/src/logging.h b/src/logging.h
index 0a96504..bca0cf6 100644
--- a/src/logging.h
+++ b/src/logging.h
@@ -113,6 +113,8 @@
 
 #define LG LOG(INFO)
 
+#define UNIMPLEMENTED(level) LOG(level) << __FUNCTION__ << " unimplemented"
+
 class LogMessage {
  public:
   LogMessage(const char* file, int line, LogSeverity severity, int error);
diff --git a/src/mark_sweep.cc b/src/mark_sweep.cc
index aefd502..ffc3977 100644
--- a/src/mark_sweep.cc
+++ b/src/mark_sweep.cc
@@ -70,7 +70,7 @@
 
 // Marks all objects in the root set.
 void MarkSweep::MarkRoots() {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
 }
 
 void MarkSweep::ScanBitmapCallback(Object* obj, void* finger, void* arg) {
@@ -96,11 +96,11 @@
 }
 
 void MarkSweep::ReMarkRoots() {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
 }
 
 void MarkSweep::SweepSystemWeaks() {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
 }
 
 void MarkSweep::SweepCallback(size_t num_ptrs, void **ptrs, void *arg) {
@@ -461,7 +461,7 @@
     // JValue unused;
     // Object *reference = *cleared;
     // TODO: dvmCallMethod(self, meth, NULL, &unused, reference);
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     *cleared = NULL;
   }
 }
diff --git a/src/object.h b/src/object.h
index 1451c54..dfcc626 100644
--- a/src/object.h
+++ b/src/object.h
@@ -167,7 +167,7 @@
   }
 
   bool IsClass() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
@@ -180,7 +180,7 @@
   }
 
   bool IsObjectArray() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
@@ -189,32 +189,32 @@
   }
 
   bool IsReference() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
   bool IsWeakReference() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
   bool IsSoftReference() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
   bool IsFinalizerReference() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
   bool IsPhantomReference() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
   bool IsArray() const {
-    LOG(FATAL) << "Unimplemented";
+    UNIMPLEMENTED(FATAL);
     return true;
   }
 
diff --git a/src/runtime.cc b/src/runtime.cc
index a02b09c..c9a2794 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -159,7 +159,7 @@
 }
 
 bool Runtime::DetachCurrentThread() {
-  LOG(WARNING) << "Unimplemented: Runtime::DetachCurrentThread";
+  UNIMPLEMENTED(WARNING);
   return true;
 }
 
diff --git a/src/space.cc b/src/space.cc
index 217c2ee..10d5f93 100644
--- a/src/space.cc
+++ b/src/space.cc
@@ -129,7 +129,7 @@
 }
 
 void Space::Grow(size_t new_size) {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
 }
 
 }  // namespace art
diff --git a/src/thread.cc b/src/thread.cc
index b98d1e5..1dee238 100644
--- a/src/thread.cc
+++ b/src/thread.cc
@@ -47,7 +47,7 @@
 }
 
 void* ThreadStart(void *arg) {
-  LOG(FATAL) << "Unimplemented";
+  UNIMPLEMENTED(FATAL);
   return NULL;
 }