1 |
+ |
/* $MidnightBSD$ */ |
2 |
|
/* |
3 |
|
* Copyright (c) 1993 Winning Strategies, Inc. |
4 |
|
* All rights reserved. |
30 |
|
*/ |
31 |
|
|
32 |
|
#include <machine/asm.h> |
33 |
< |
__FBSDID("$FreeBSD$"); |
33 |
> |
__FBSDID("$FreeBSD: stable/10/lib/libc/i386/string/strrchr.S 249582 2013-04-17 11:40:10Z gabor $"); |
34 |
|
|
35 |
|
/* |
36 |
|
* strrchr(s, c) |
37 |
< |
* return a pointer to the last occurance of the character c in |
37 |
> |
* return a pointer to the last occurrence of the character c in |
38 |
|
* string s, or NULL if c does not occur in the string. |
39 |
|
* |
40 |
|
* %edx - pointer iterating through string |
41 |
< |
* %eax - pointer to last occurance of 'c' |
41 |
> |
* %eax - pointer to last occurrence of 'c' |
42 |
|
* %cl - character we're comparing against |
43 |
|
* %bl - character at %edx |
44 |
|
* |
64 |
|
popl %ebx |
65 |
|
ret |
66 |
|
END(strrchr) |
67 |
+ |
|
68 |
+ |
WEAK_ALIAS(rindex, strrchr) |
69 |
|
|
70 |
|
.section .note.GNU-stack,"",%progbits |