[svn] / trunk / xvidcore / src / utils / x86_asm / mem_transfer_mmx.asm Repository:
ViewVC logotype

Diff of /trunk/xvidcore/src/utils/x86_asm/mem_transfer_mmx.asm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1540, Sun Aug 29 10:02:38 2004 UTC revision 1583, Sun Dec 19 13:16:50 2004 UTC
# Line 21  Line 21 
21  ; *  along with this program ; if not, write to the Free Software  ; *  along with this program ; if not, write to the Free Software
22  ; *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA  ; *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
23  ; *  ; *
24  ; * $Id: mem_transfer_mmx.asm,v 1.15 2004-08-29 10:02:38 edgomez Exp $  ; * $Id: mem_transfer_mmx.asm,v 1.16 2004-12-19 13:16:50 syskin Exp $
25  ; *  ; *
26  ; ***************************************************************************/  ; ***************************************************************************/
27    
# Line 71  Line 71 
71  cglobal transfer_8to16subro_mmx  cglobal transfer_8to16subro_mmx
72  cglobal transfer_8to16sub2_mmx  cglobal transfer_8to16sub2_mmx
73  cglobal transfer_8to16sub2_xmm  cglobal transfer_8to16sub2_xmm
74    cglobal transfer_8to16sub2ro_xmm
75  cglobal transfer_16to8add_mmx  cglobal transfer_16to8add_mmx
76  cglobal transfer8x8_copy_mmx  cglobal transfer8x8_copy_mmx
77    
# Line 399  Line 400 
400    ret    ret
401  .endfunc  .endfunc
402    
403    
404    ;-----------------------------------------------------------------------------
405    ;
406    ; void transfer_8to16sub2ro_xmm(int16_t * const dct,
407    ;                               const uint8_t * const cur,
408    ;                               const uint8_t * ref1,
409    ;                               const uint8_t * ref2,
410    ;                               const uint32_t stride)
411    ;
412    ;-----------------------------------------------------------------------------
413    
414    %macro COPY_8_TO_16_SUB2RO_SSE 1
415      movq mm0, [eax]      ; cur
416      movq mm2, [eax+edx]
417      movq mm1, mm0
418      movq mm3, mm2
419    
420      punpcklbw mm0, mm7
421      punpcklbw mm2, mm7
422      movq mm4, [ebx]     ; ref1
423      pavgb mm4, [esi]     ; ref2
424      punpckhbw mm1, mm7
425      punpckhbw mm3, mm7
426      movq mm5, [ebx+edx] ; ref
427      pavgb mm5, [esi+edx] ; ref2
428    
429      movq mm6, mm4
430      punpcklbw mm4, mm7
431      punpckhbw mm6, mm7
432      psubsw mm0, mm4
433      psubsw mm1, mm6
434      lea esi, [esi+2*edx]
435      movq mm6, mm5
436      punpcklbw mm5, mm7
437      punpckhbw mm6, mm7
438      psubsw mm2, mm5
439      lea eax, [eax+2*edx]
440      psubsw mm3, mm6
441      lea ebx, [ebx+2*edx]
442    
443      movq [ecx+%1*32+ 0], mm0 ; dst
444      movq [ecx+%1*32+ 8], mm1
445      movq [ecx+%1*32+16], mm2
446      movq [ecx+%1*32+24], mm3
447    %endmacro
448    
449    ALIGN 16
450    transfer_8to16sub2ro_xmm:
451      pxor mm7, mm7
452      mov ecx, [esp  + 4] ; Dst
453      mov eax, [esp  + 8] ; Cur
454      push ebx
455      mov ebx, [esp+4+12] ; Ref1
456      push esi
457      mov esi, [esp+8+16] ; Ref2
458      mov edx, [esp+8+20] ; Stride
459    
460      COPY_8_TO_16_SUB2RO_SSE 0
461      COPY_8_TO_16_SUB2RO_SSE 1
462      COPY_8_TO_16_SUB2RO_SSE 2
463      COPY_8_TO_16_SUB2RO_SSE 3
464    
465      pop esi
466      pop ebx
467      ret
468    .endfunc
469    
470    
471  ;-----------------------------------------------------------------------------  ;-----------------------------------------------------------------------------
472  ;  ;
473  ; void transfer_16to8add_mmx(uint8_t * const dst,  ; void transfer_16to8add_mmx(uint8_t * const dst,

Legend:
Removed from v.1540  
changed lines
  Added in v.1583

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4