Revision a2dfe8d1

View differences:

libavcodec/x86/h264_intrapred.asm
866 866
%endif
867 867

  
868 868
;-----------------------------------------------------------------------------
869
; void pred8x8_dc_mmxext(uint8_t *src, int stride)
870
;-----------------------------------------------------------------------------
871
%ifdef CONFIG_GPL
872
INIT_MMX
873
cglobal pred8x8_dc_mmxext, 2,5
874
    sub       r0, r1
875
    pxor      m7, m7
876
    movd      m0, [r0+0]
877
    movd      m1, [r0+4]
878
    psadbw    m0, m7            ; s0
879
    mov       r4, r0
880
    psadbw    m1, m7            ; s1
881

  
882
    movzx    r2d, byte [r0+r1*1-1]
883
    movzx    r3d, byte [r0+r1*2-1]
884
    lea       r0, [r0+r1*2]
885
    add      r2d, r3d
886
    movzx    r3d, byte [r0+r1*1-1]
887
    add      r2d, r3d
888
    movzx    r3d, byte [r0+r1*2-1]
889
    add      r2d, r3d
890
    lea       r0, [r0+r1*2]
891
    movd      m2, r2d            ; s2
892
    movzx    r2d, byte [r0+r1*1-1]
893
    movzx    r3d, byte [r0+r1*2-1]
894
    lea       r0, [r0+r1*2]
895
    add      r2d, r3d
896
    movzx    r3d, byte [r0+r1*1-1]
897
    add      r2d, r3d
898
    movzx    r3d, byte [r0+r1*2-1]
899
    add      r2d, r3d
900
    movd      m3, r2d            ; s3
901

  
902
    punpcklwd m0, m1
903
    mov       r0, r4
904
    punpcklwd m2, m3
905
    punpckldq m0, m2            ; s0, s1, s2, s3
906
    pshufw    m3, m0, 11110110b ; s2, s1, s3, s3
907
    lea       r2, [r0+r1*2]
908
    pshufw    m0, m0, 01110100b ; s0, s1, s3, s1
909
    paddw     m0, m3
910
    lea       r3, [r2+r1*2]
911
    psrlw     m0, 2
912
    pavgw     m0, m7            ; s0+s2, s1, s3, s1+s3
913
    lea       r4, [r3+r1*2]
914
    packuswb  m0, m0
915
    punpcklbw m0, m0
916
    movq      m1, m0
917
    punpcklbw m0, m0
918
    punpckhbw m1, m1
919
    movq [r0+r1*1], m0
920
    movq [r0+r1*2], m0
921
    movq [r2+r1*1], m0
922
    movq [r2+r1*2], m0
923
    movq [r3+r1*1], m1
924
    movq [r3+r1*2], m1
925
    movq [r4+r1*1], m1
926
    movq [r4+r1*2], m1
927
    RET
928
%endif
929

  
930
;-----------------------------------------------------------------------------
869 931
; void pred8x8_dc_rv40(uint8_t *src, int stride)
870 932
;-----------------------------------------------------------------------------
871 933

  
libavcodec/x86/h264_intrapred_init.c
46 46
void ff_pred16x16_tm_vp8_sse2      (uint8_t *src, int stride);
47 47
void ff_pred8x8_top_dc_mmxext      (uint8_t *src, int stride);
48 48
void ff_pred8x8_dc_rv40_mmxext     (uint8_t *src, int stride);
49
void ff_pred8x8_dc_mmxext          (uint8_t *src, int stride);
49 50
void ff_pred8x8_vertical_mmx       (uint8_t *src, int stride);
50 51
void ff_pred8x8_horizontal_mmx     (uint8_t *src, int stride);
51 52
void ff_pred8x8_horizontal_mmxext  (uint8_t *src, int stride);
......
101 102
            h->pred4x4  [DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_mmxext;
102 103
        if (codec_id == CODEC_ID_SVQ3 || codec_id == CODEC_ID_H264) {
103 104
            h->pred8x8  [TOP_DC_PRED8x8      ] = ff_pred8x8_top_dc_mmxext;
105
            h->pred8x8  [DC_PRED8x8          ] = ff_pred8x8_dc_mmxext;
104 106
        }
105 107
#endif
106 108
        if (codec_id == CODEC_ID_VP8) {

Also available in: Unified diff