[MIPS] Inverse DCT optimizations

Change-Id: I1f3aa64d8d19b515876fe83b6df86c27bffa4530
diff --git a/jddctmgr.c b/jddctmgr.c
index 97b516a..8bc9668 100644
--- a/jddctmgr.c
+++ b/jddctmgr.c
@@ -57,6 +57,10 @@
 		JSAMPARRAY output_buf, JDIMENSION output_col);
 #endif
 
+#ifdef ANDROID_MIPS_IDCT
+extern void jpeg_idct_mips(j_decompress_ptr, jpeg_component_info *, JCOEFPTR, JSAMPARRAY, JDIMENSION);
+#endif
+
 /*
  * The decompressor input side (jdinput.c) saves away the appropriate
  * quantization table for each component at the start of the first scan
@@ -164,7 +168,14 @@
 	method_ptr = jpeg_idct_intelsse;
 	method = JDCT_ISLOW; /* Use quant table of ISLOW.*/
 	break;
-#else
+#else /* ANDROID_INTELSSE2_IDCT */
+#ifdef ANDROID_MIPS_IDCT
+      case JDCT_ISLOW:
+      case JDCT_IFAST:
+	method_ptr = jpeg_idct_mips;
+	method = JDCT_IFAST;
+	break;
+#else /* ANDROID_MIPS_IDCT */
 #ifdef DCT_ISLOW_SUPPORTED
       case JDCT_ISLOW:
 	method_ptr = jpeg_idct_islow;
@@ -177,6 +188,7 @@
 	method = JDCT_IFAST;
 	break;
 #endif
+#endif /* ANDROID_MIPS_IDCT */
 #endif /* ANDROID_INTELSSE2_IDCT*/
 #endif /* ANDROID_ARMV6_IDCT */
 #ifdef DCT_FLOAT_SUPPORTED