Add decoder support to ext_skip

At the frame header level, add the checking on whether an inter-coded
frame allows the use of 'skip_mode'. At the block level, add the
decoding of 'skip_mode' for all the blocks if 'skip_mode' is allowed
for the current frame. If 'skip_mode' is set, no further bit needs to
read out, and the block is set as:
- Inter-coded in compound mode;
- With the nearest forward and backward reference frames;
- In NEAREST_NEARESTMV mode;
- In SIMPLE_TRANSLATION motion mode;
- In COMPOUND_AVERAGE compound type; and
- Skip set for residual.

Change-Id: I50297f63a81135109332c4a51b516bffd7726777
diff --git a/av1/common/pred_common.h b/av1/common/pred_common.h
index 169035b..882c9a2 100644
--- a/av1/common/pred_common.h
+++ b/av1/common/pred_common.h
@@ -108,6 +108,16 @@
 }
 #endif
 
+#if CONFIG_EXT_SKIP
+static INLINE int av1_get_skip_mode_context(const MACROBLOCKD *xd) {
+  const MODE_INFO *const above_mi = xd->above_mi;
+  const MODE_INFO *const left_mi = xd->left_mi;
+  const int above_skip_mode = above_mi ? above_mi->mbmi.skip_mode : 0;
+  const int left_skip_mode = left_mi ? left_mi->mbmi.skip_mode : 0;
+  return above_skip_mode + left_skip_mode;
+}
+#endif  // CONFIG_EXT_SKIP
+
 static INLINE int av1_get_skip_context(const MACROBLOCKD *xd) {
   const MODE_INFO *const above_mi = xd->above_mi;
   const MODE_INFO *const left_mi = xd->left_mi;