From 1609edca75bced597fdb4da9fb5a2817a72385db Mon Sep 17 00:00:00 2001 From: "Tim J. Robbins" Date: Wed, 12 Mar 2003 06:46:16 +0000 Subject: [PATCH] MFp4: Reduce code size by 26 bytes by only aligning the jump targets that are at the top of loops. --- lib/libc/i386/string/wmemchr.S | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/lib/libc/i386/string/wmemchr.S b/lib/libc/i386/string/wmemchr.S index 4163735fc766..a4ef08191156 100644 --- a/lib/libc/i386/string/wmemchr.S +++ b/lib/libc/i386/string/wmemchr.S @@ -68,46 +68,37 @@ bigloop:cmpl %eax,(%edi) decl %ecx jnz bigloop jmp small -.p2align 2,0x90 found: movl %edi,%eax popl %ebx popl %edi ret -.p2align 2,0x90 found4: leal 4(%edi),%edi jmp found -.p2align 2,0x90 found8: leal 8(%edi),%edi jmp found -.p2align 2,0x90 found12:leal 12(%edi),%edi jmp found -.p2align 2,0x90 found16:leal 16(%edi),%edi jmp found -.p2align 2,0x90 found20:leal 20(%edi),%edi jmp found -.p2align 2,0x90 found24:leal 24(%edi),%edi jmp found -.p2align 2,0x90 found28:leal 28(%edi),%edi jmp found /* * Search remaining part of string. */ -.p2align 2,0x90 small: movl %ebx,%ecx andl $7,%ecx jz no +.p2align 2,0x90 smltop: cmpl %eax,(%edi) je found leal 4(%edi),%edi decl %ecx jnz smltop -.p2align 2,0x90 no: xorl %eax,%eax popl %ebx popl %edi