libavcodec/vp8.c:1321: error: Buffer Overrun L2
  Offset: [2, 7] (⇐ 2 + [0, 5]) Size: 3 by call to `vp8_mc`.

libavcodec/vp8.c:1301:1: Parameter `s->put_pixels_tab[*]`
1299.  * Apply motion vectors to prediction buffer, chapter 18.
1300.  */
1301. static av_always_inline
      ^
1302. void inter_predict(VP8Context *s, uint8_t *dst[3], VP8Macroblock *mb,
1303.                    int mb_x, int mb_y)

libavcodec/vp8.c:1321:17: Call
1319.         for (y = 0; y < 4; y++) {
1320.             for (x = 0; x < 4; x++) {
1321.                 vp8_mc(s, 1, dst[0] + 4*y*s->linesize + x*4,
                      ^
1322.                        ref->data[0], &bmv[4*y + x],
1323.                        4*x + x_off, 4*y + y_off, 4, 4,

libavcodec/vp8.c:1222:13: <Offset trace>
1220.     if (AV_RN32A(mv)) {
1221.         static const uint8_t idx[3][8] = {
1222.             { 0, 1, 2, 1, 2, 1, 2, 1 }, // nr. of left extra pixels,
                  ^
1223.                                         // also function pointer index
1224.             { 0, 3, 5, 3, 5, 3, 5, 3 }, // nr. of extra pixels required

libavcodec/vp8.c:1222:13: Assignment
  1220.     if (AV_RN32A(mv)) {
  1221.         static const uint8_t idx[3][8] = {
  1222.             { 0, 1, 2, 1, 2, 1, 2, 1 }, // nr. of left extra pixels,
                    ^
  1223.                                         // also function pointer index
  1224.             { 0, 3, 5, 3, 5, 3, 5, 3 }, // nr. of extra pixels required

libavcodec/vp8.c:1228:9: Assignment
  1226.         };
  1227.         int mx = (mv->x << luma)&7, mx_idx = idx[0][mx];
  1228.         int my = (mv->y << luma)&7, my_idx = idx[0][my];
                ^
  1229. 
  1230.         x_off += mv->x >> (3 - luma);

libavcodec/vp8.c:1213:1: <Length trace>
1211.  * @param mc_func motion compensation function pointers (bilinear or sixtap MC)
1212.  */
1213. static av_always_inline
      ^
1214. void vp8_mc(VP8Context *s, int luma,
1215.             uint8_t *dst, uint8_t *src, const VP56mv *mv,

libavcodec/vp8.c:1213:1: Parameter `*mc_func`
  1211.  * @param mc_func motion compensation function pointers (bilinear or sixtap MC)
  1212.  */
  1213. static av_always_inline
        ^
  1214. void vp8_mc(VP8Context *s, int luma,
  1215.             uint8_t *dst, uint8_t *src, const VP56mv *mv,

libavcodec/vp8.c:1242:9: Array access: Offset: [2, 7] (⇐ 2 + [0, 5]) Size: 3 by call to `vp8_mc` 
  1240.             src = s->edge_emu_buffer + mx_idx + linesize * my_idx;
  1241.         }
  1242.         mc_func[my_idx][mx_idx](dst, linesize, src, linesize, block_h, mx, my);
                ^
  1243.     } else
  1244.         mc_func[0][0](dst, linesize, src + y_off * linesize + x_off, linesize, block_h, 0, 0);

static av_always_inline
void vp8_mc(VP8Context *s, int luma,
            uint8_t *dst, uint8_t *src, const VP56mv *mv,
            int x_off, int y_off, int block_w, int block_h,
            int width, int height, int linesize,
            vp8_mc_func mc_func[3][3])
{
    if (AV_RN32A(mv)) {
        static const uint8_t idx[3][8] = {
            { 0, 1, 2, 1, 2, 1, 2, 1 },
            { 0, 3, 5, 3, 5, 3, 5, 3 },
            { 0, 2, 3, 2, 3, 2, 3, 2 },
        };
        int mx = (mv->x << luma)&7, mx_idx = idx[0][mx];
        int my = (mv->y << luma)&7, my_idx = idx[0][my];
        x_off += mv->x >> (3 - luma);
        y_off += mv->y >> (3 - luma);
        src += y_off * linesize + x_off;
        if (x_off < mx_idx || x_off >= width  - block_w - idx[2][mx] ||
            y_off < my_idx || y_off >= height - block_h - idx[2][my]) {
            ff_emulated_edge_mc(s->edge_emu_buffer, src - my_idx * linesize - mx_idx, linesize,
                                block_w + idx[1][mx], block_h + idx[1][my],
                                x_off - mx_idx, y_off - my_idx, width, height);
            src = s->edge_emu_buffer + mx_idx + linesize * my_idx;
        }
        mc_func[my_idx][mx_idx](dst, linesize, src, linesize, block_h, mx, my);
    } else
        mc_func[0][0](dst, linesize, src + y_off * linesize + x_off, linesize, block_h, 0, 0);
}
['static av_always_inline\nvoid inter_predict(VP8Context *s, uint8_t *dst[3], VP8Macroblock *mb,\n                   int mb_x, int mb_y)\n{\n    int x_off = mb_x << 4, y_off = mb_y << 4;\n    int width = 16*s->mb_width, height = 16*s->mb_height;\n    AVFrame *ref = s->framep[mb->ref_frame];\n    VP56mv *bmv = mb->bmv;\n    if (mb->mode < VP8_MVMODE_SPLIT) {\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 0, 16, 16, width, height, &mb->mv);\n    } else switch (mb->partitioning) {\n    case VP8_SPLITMVMODE_4x4: {\n        int x, y;\n        VP56mv uvmv;\n        for (y = 0; y < 4; y++) {\n            for (x = 0; x < 4; x++) {\n                vp8_mc(s, 1, dst[0] + 4*y*s->linesize + x*4,\n                       ref->data[0], &bmv[4*y + x],\n                       4*x + x_off, 4*y + y_off, 4, 4,\n                       width, height, s->linesize,\n                       s->put_pixels_tab[2]);\n            }\n        }\n        x_off >>= 1; y_off >>= 1; width >>= 1; height >>= 1;\n        for (y = 0; y < 2; y++) {\n            for (x = 0; x < 2; x++) {\n                uvmv.x = mb->bmv[ 2*y    * 4 + 2*x  ].x +\n                         mb->bmv[ 2*y    * 4 + 2*x+1].x +\n                         mb->bmv[(2*y+1) * 4 + 2*x  ].x +\n                         mb->bmv[(2*y+1) * 4 + 2*x+1].x;\n                uvmv.y = mb->bmv[ 2*y    * 4 + 2*x  ].y +\n                         mb->bmv[ 2*y    * 4 + 2*x+1].y +\n                         mb->bmv[(2*y+1) * 4 + 2*x  ].y +\n                         mb->bmv[(2*y+1) * 4 + 2*x+1].y;\n                uvmv.x = (uvmv.x + 2 + (uvmv.x >> (INT_BIT-1))) >> 2;\n                uvmv.y = (uvmv.y + 2 + (uvmv.y >> (INT_BIT-1))) >> 2;\n                if (s->profile == 3) {\n                    uvmv.x &= ~7;\n                    uvmv.y &= ~7;\n                }\n                vp8_mc(s, 0, dst[1] + 4*y*s->uvlinesize + x*4,\n                       ref->data[1], &uvmv,\n                       4*x + x_off, 4*y + y_off, 4, 4,\n                       width, height, s->uvlinesize,\n                       s->put_pixels_tab[2]);\n                vp8_mc(s, 0, dst[2] + 4*y*s->uvlinesize + x*4,\n                       ref->data[2], &uvmv,\n                       4*x + x_off, 4*y + y_off, 4, 4,\n                       width, height, s->uvlinesize,\n                       s->put_pixels_tab[2]);\n            }\n        }\n        break;\n    }\n    case VP8_SPLITMVMODE_16x8:\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 0, 16, 8, width, height, &bmv[0]);\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 8, 16, 8, width, height, &bmv[1]);\n        break;\n    case VP8_SPLITMVMODE_8x16:\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 0, 8, 16, width, height, &bmv[0]);\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    8, 0, 8, 16, width, height, &bmv[1]);\n        break;\n    case VP8_SPLITMVMODE_8x8:\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 0, 8, 8, width, height, &bmv[0]);\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    8, 0, 8, 8, width, height, &bmv[1]);\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    0, 8, 8, 8, width, height, &bmv[2]);\n        vp8_mc_part(s, dst, ref, x_off, y_off,\n                    8, 8, 8, 8, width, height, &bmv[3]);\n        break;\n    }\n}', 'static av_always_inline\nvoid vp8_mc(VP8Context *s, int luma,\n            uint8_t *dst, uint8_t *src, const VP56mv *mv,\n            int x_off, int y_off, int block_w, int block_h,\n            int width, int height, int linesize,\n            vp8_mc_func mc_func[3][3])\n{\n    if (AV_RN32A(mv)) {\n        static const uint8_t idx[3][8] = {\n            { 0, 1, 2, 1, 2, 1, 2, 1 },\n            { 0, 3, 5, 3, 5, 3, 5, 3 },\n            { 0, 2, 3, 2, 3, 2, 3, 2 },\n        };\n        int mx = (mv->x << luma)&7, mx_idx = idx[0][mx];\n        int my = (mv->y << luma)&7, my_idx = idx[0][my];\n        x_off += mv->x >> (3 - luma);\n        y_off += mv->y >> (3 - luma);\n        src += y_off * linesize + x_off;\n        if (x_off < mx_idx || x_off >= width  - block_w - idx[2][mx] ||\n            y_off < my_idx || y_off >= height - block_h - idx[2][my]) {\n            ff_emulated_edge_mc(s->edge_emu_buffer, src - my_idx * linesize - mx_idx, linesize,\n                                block_w + idx[1][mx], block_h + idx[1][my],\n                                x_off - mx_idx, y_off - my_idx, width, height);\n            src = s->edge_emu_buffer + mx_idx + linesize * my_idx;\n        }\n        mc_func[my_idx][mx_idx](dst, linesize, src, linesize, block_h, mx, my);\n    } else\n        mc_func[0][0](dst, linesize, src + y_off * linesize + x_off, linesize, block_h, 0, 0);\n}']