summaryrefslogtreecommitdiff
path: root/sysdeps/powerpc/powerpc64/power7/memchr.S
Commit message (Collapse)AuthorAgeFilesLines
* Update copyright dates with scripts/update-copyrights.Joseph Myers2015-01-021-1/+1
|
* Update copyright notices with scripts/update-copyrightsAllan McRae2014-01-011-1/+1
|
* Fix uses of CALL_MCOUNT in ppc64 assembler sourcesAndreas Schwab2013-12-191-1/+1
|
* PowerPC LE memchr and memrchrAlan Modra2013-10-041-104/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | http://sourceware.org/ml/libc-alpha/2013-08/msg00105.html Like strnlen, memchr and memrchr had a number of defects fixed by this patch as well as adding little-endian support. The first one I noticed was that the entry to the main loop needlessly checked for "are we done yet?" when we know the size is large enough that we can't be done. The second defect I noticed was that the main loop count was wrong, which in turn meant that the small loop needed to handle an extra word. Thirdly, there is nothing to say that the string can't wrap around zero, except of course that we'd normally hit a segfault on trying to read from address zero. Fixing that simplified a number of places: - /* Are we done already? */ - addi r9,r8,8 - cmpld r9,r7 - bge L(null) becomes + cmpld r8,r7 + beqlr However, the exit gets an extra test because I test for being on the last word then if so whether the byte offset is less than the end. Overall, the change is a win. Lastly, memrchr used the wrong cache hint. * sysdeps/powerpc/powerpc64/power7/memchr.S: Replace rlwimi with insrdi. Make better use of reg selection to speed exit slightly. Schedule entry path a little better. Remove useless "are we done" checks on entry to main loop. Handle wrapping around zero address. Correct main loop count. Handle single left-over word from main loop inline rather than by using loop_small. Remove extra word case in loop_small caused by wrong loop count. Add little-endian support. * sysdeps/powerpc/powerpc32/power7/memchr.S: Likewise. * sysdeps/powerpc/powerpc64/power7/memrchr.S: Likewise. Use proper cache hint. * sysdeps/powerpc/powerpc32/power7/memrchr.S: Likewise. * sysdeps/powerpc/powerpc64/power7/rawmemchr.S: Add little-endian support. Avoid rlwimi. * sysdeps/powerpc/powerpc32/power7/rawmemchr.S: Likewise.
* Remove powerpc64 bounded-pointers code.Joseph Myers2013-03-061-5/+3
|
* Update copyright notices with scripts/update-copyrights.Joseph Myers2013-01-021-1/+1
|
* [Powerpc] Tune/optimize powerpc{32,64}/power7/memchr.S.Will Schmidt2012-08-211-24/+61
| | | | | | | | | | | | Assorted tweaking, twisting and tuning to squeeze a few additional cycles out of the memchr code. Changes include bypassing the shift pairs (sld,srd) when they are not required, and unrolling the small_loop that handles short and trailing strings. Per scrollpipe data measuring aligned strings for 64-bit, these changes save between five and eight cycles (9-13% overall) for short strings (<32), Longer aligned strings see slight improvement of 1-3% due to bypassing the shifts and the instruction rearranging.
* Replace FSF snail mail address with URLs.Paul Eggert2012-02-091-3/+2
|
* powerpc: Various P7-optimized string functionsLuis Machado2010-08-191-0/+171