[FFmpeg-cvslog] r21432 - trunk/libavcodec/h264_cavlc.c
Michael Niedermayer
michaelni
Mon Jan 25 10:13:47 CET 2010
On Sun, Jan 24, 2010 at 11:59:25PM +0000, M?ns Rullg?rd wrote:
> michael <subversion at mplayerhq.hu> writes:
>
> > Author: michael
> > Date: Sun Jan 24 19:42:22 2010
> > New Revision: 21432
> >
> > Log:
> > a[b-1] -> (a-1)[b].
> > Helps gcc not to add seperate -1 instructions.
>
> Do you have some asm to illustrate?
from h264_cavlc.c with this patch
and thats with gcc-4.4 (Debian 4.4.3-1) 4.4.3
before:
movl %eax, %edx
movl %eax, %ecx
leal -1(%rbp), %r10d <-----------
shrl $3, %edx
andl $7, %ecx
mov %edx, %edx
movl (%r11,%rdx), %edx
bswap %edx
sall %cl, %edx
movslq %r10d,%rcx <-----------
leaq (%rcx,%rcx,2), %r12 <-----------
shrl $-9, %edx
mov %edx, %edx
leaq 0(,%rdx,4), %rcx
addq total_zeros_vlc+8(,%r12,8), %rcx
after:
movl %eax, %edx
movl %eax, %ecx
shrl $3, %edx
andl $7, %ecx
mov %edx, %edx
movl (%r11,%rdx), %edx
bswap %edx
sall %cl, %edx
movslq %ebp,%rcx <-------------
leaq -3(%rcx,%rcx,2), %r10 <-------------
shrl $-9, %edx
mov %edx, %edx
leaq 0(,%rdx,4), %rcx
addq total_zeros_vlc+8(,%r10,8), %rcx
you can also see 2 of the
mov %edx, %edx
in there that i spoke off
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Awnsering whenever a program halts or runs forever is
On a turing machine, in general impossible (turings halting problem).
On any real computer, always possible as a real computer has a finite number
of states N, and will either halt in less than N cycles or never halt.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-cvslog/attachments/20100125/dad3531c/attachment-0001.pgp>
More information about the ffmpeg-cvslog
mailing list