1/* 2 * Copyright (c) 1993 Winning Strategies, Inc. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 16 unchanged lines hidden (view full) --- 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 28 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 */ 30 31#if defined(LIBC_RCS) && !defined(lint) 32 .text |
33 .asciz "$FreeBSD: head/lib/libc/i386/string/strcmp.S 91999 2002-03-10 12:08:28Z billf $" |
34#endif /* LIBC_RCS and not lint */ 35 36#include <machine/asm.h> 37 38/* 39 * strcmp(s1, s2) 40 * return an integer greater than, equal to, or less than 0, 41 * according as string s1 is greater than, equal to, or less --- 4 unchanged lines hidden (view full) --- 46 * 47 * Written by: 48 * J.T. Conklin (jtc@wimsey.com), Winning Strategies, Inc. 49 */ 50 51/* 52 * I've unrolled the loop eight times: large enough to make a 53 * significant difference, and small enough not to totally trash the |
54 * cache. |
55 */ 56 57ENTRY(strcmp) 58 movl 0x04(%esp),%eax 59 movl 0x08(%esp),%edx 60 jmp L2 /* Jump into the loop! */ 61 62 .align 2,0x90 --- 61 unchanged lines hidden --- |