[PATCH] powerpc: strstr optimization

Steven Munroe munroesj@linux.vnet.ibm.comcom
Mon May 11 21:04:00 GMT 2015


On Mon, 2015-05-11 at 20:19 +0000, Joseph Myers wrote:
> On Mon, 11 May 2015, Steven Munroe wrote:
> 
> > I think we should move on with (commit) Raji's patch as is. 
> 
> Does the patch avoid quadratic worst case?  Quadratic performance in 
> strstr is an unambiguous regression, allowing for denial-of-service, that 
> should not be introduced on any platform (cf bug 12100).  Indeed, gnulib 
> has a configure test for quadratic strstr, so if you introduce quadratic 
> worst case then the effect will be that all applications using gnulib 
> automatically configure themselves to use gnulib's strstr and not glibc's 
> at all.
> 

There was an assertion that there "might be" a quadratic worse case. No
proof was offered that there was such.

Raji do you have the data for this?




More information about the Libc-alpha mailing list