Add kMips and mips32r2 target attribute. Remove NoFramePointerElim.

MIPS ICS devices today are mips32r2. Tested LLVM on MIPS devices without
synci and rdhwr instructions to make sure LLVM/mips32r2 is working.

Change-Id: If1db7fe268e9f3b7d27eedbacd1d55620d57612a
diff --git a/src/compiler_llvm/compilation_unit.cc b/src/compiler_llvm/compilation_unit.cc
index ac956ef..fe3c3ea 100644
--- a/src/compiler_llvm/compilation_unit.cc
+++ b/src/compiler_llvm/compilation_unit.cc
@@ -117,10 +117,10 @@
     target_attr = "";
     break;
 
-  //case kMips:
-  //  target_triple = "mipsel-unknown-linux";
-  //  target_attr = "";
-  //  break;
+  case kMips:
+    target_triple = "mipsel-unknown-linux";
+    target_attr = "mips32r2";
+    break;
 
   default:
     LOG(FATAL) << "Unknown instruction set: " << insn_set_;
@@ -135,8 +135,6 @@
   // Target options
   llvm::TargetOptions target_options;
 
-  target_options.NoFramePointerElim = true;
-  target_options.NoFramePointerElimNonLeaf = true;
   target_options.FloatABIType = llvm::FloatABI::Soft;
   target_options.UseSoftFloat = false;
   target_options.NoFramePointerElim = true;
diff --git a/src/compiler_llvm/utils_llvm.cc b/src/compiler_llvm/utils_llvm.cc
index a924793..405d7e2 100644
--- a/src/compiler_llvm/utils_llvm.cc
+++ b/src/compiler_llvm/utils_llvm.cc
@@ -161,7 +161,7 @@
     }
   }
 
-  CHECK(0) << "Error: Can't find symbol " << name;
+  LOG(FATAL) << "Error: Can't find symbol " << name;
   return 0;
 }
 
diff --git a/src/constants.h b/src/constants.h
index 5c1323f..bb17c2d 100644
--- a/src/constants.h
+++ b/src/constants.h
@@ -25,7 +25,8 @@
   kNone,
   kArm,
   kThumb2,
-  kX86
+  kX86,
+  kMips
 };
 
 enum InvokeType {