This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libc/5514] memmem is O(n^2), but should be O(n)


------- Additional Comments From ebb9 at byu dot net  2008-03-29 16:43 -------
Created an attachment (id=2339)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=2339&action=view)
fixed-allocation linear memmem/strstr

2008-03-29  Eric Blake	<ebb9@byu.net>

	Rewrite string searches to O(n) rather than O(n^2).
	* string/str-two-way.h: New file, for linear fixed-allocation
	string searching.
	* string/memmem.c: New implementation.
	* string/strstr.c: New implementation.
	* string/strcasestr.c: New implementation.


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
Attachment #2161 is|0                           |1
           obsolete|                            |
Attachment #2162 is|0                           |1
           obsolete|                            |


http://sourceware.org/bugzilla/show_bug.cgi?id=5514

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]