This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: COMMITTED: Add memmem to libiberty
- From: Ian Lance Taylor <iant at google dot com>
- To: Ralf Wildenhues <Ralf dot Wildenhues at gmx dot de>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 30 Mar 2009 15:27:44 -0700
- Subject: Re: COMMITTED: Add memmem to libiberty
- References: <m3eiwivbd6.fsf@google.com> <20090328153257.GA3612@gmx.de>
Ralf Wildenhues <Ralf.Wildenhues@gmx.de> writes:
> Was it on purpose that you used an older version of the gnulib memmem
> that still exhibits O(n^2) worst-case complexity?
I've now taken a look at the current gnulib memmem code, and I find it
mildly discouraging since it uses stdint.h and limits.h. Of course
gnulib provides these as well, but there is a limit to the amount of
gnulib functionality I want to pull into libiberty. memmem is not used
in a performance critical way, so I'm inclined to let this slide for
now, and perhaps revisit it later.
Ian