[PATCH] memrchr testcase
Ondřej Bílka
neleai@seznam.cz
Mon Sep 2 09:05:00 GMT 2013
On Sat, Aug 31, 2013 at 05:15:06PM -0300, Adhemerval Zanella wrote:
> On 08/31/2013 04:09 AM, OndÅej BÃlka wrote:
> > On Thu, Aug 29, 2013 at 11:29:27AM -0300, Adhemerval Zanella wrote:
> >> Hi all,
> >>
> >> When reviewing the PPC LE patches from Alan I noticed GLIBC don't have a
> >> memrchr testcase. In fact when I was coding this path I found out an
> >> issue with POWER7 implementation which Alan's memchr/memrch patch
> >> already addresses (so I won't bother sending the patch).
> >>
> >> I used the memchr one as base and adjusting for a reverse search (I removed
> >> from the check with a large len which obvious generate invalid memory accesses).
> >>
> > I would prefer to write it using ifdef AS_MEMRCHR in memchr testcase.
> > This way can we can keep these in sync when we will need to change
> > testcase.
>
> In my view, adding ifdefs will only pollute the test in this case. Different for memcpy/mempcpy
> where the bulk of testcase is essentially the same (with adjustments made only name and functions
> calls), I had to modify the memchr testcase slight to remove checks that did not make sense
> for memrchr (to check a very large input
If you thisnk so then its OK.
More information about the Libc-alpha
mailing list