delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/06/08/03:15:19

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Fri, 08 Jun 2001 10:06:51 +0300
From: "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il>
To: dj AT redhat DOT com
Message-Id: <9003-Fri08Jun2001100651+0300-eliz@is.elta.co.il>
X-Mailer: Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.9
CC: gcc AT gcc DOT gnu DOT org, gdb AT sources DOT redhat DOT com, binutils AT sources DOT redhat DOT com,
cygwin AT sources DOT redhat DOT com
In-reply-to: <200106080127.VAA01308@greed.delorie.com> (message from DJ
Delorie on Thu, 7 Jun 2001 21:27:31 -0400)
Subject: Re: Another RFC: regex in libiberty
Reply-to: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
References: <200106080127 DOT VAA01308 AT greed DOT delorie DOT com>

> Date: Thu, 7 Jun 2001 21:27:31 -0400
> From: DJ Delorie <dj AT redhat DOT com>
> 
> I didn't get a clear feeling about what people wanted wrt this.  I saw
> three people propose three versions of regex, not much to go on.  Is
> this a big deal?  Will it really get used by everyone who currently
> has their own regex?  Is it important to try to use a BSD-licensed
> regex to minimize future problems?
> 
> The two contenders seem to be a modified GNU regex and the
> ever-popular Henry Spencer's regex.  Does anyone have any strong
> opinions for either of these, or against any regex in libiberty at
> all?

One notorious problem with GNU regex is that it is quite slow for many
simple jobs, such as matching a simple regular expression with no
backtracking.  It seems that the main reason for this slowness is the
fact that GNU regex supports null characters in strings.  For
examnple, Sed 3.02 compiled with GNU regex is about 2-4 times slower
on simple jobs than the same Sed compiled with Spencer's regex
library.  (The DJGPP port of Sed is actually distributed with two
executables, one build with GNU regex, the other with Spencer's, for
this very reason.)

So perhaps it might help to have more than just GNU regex in
libiberty, for those applications that don't need to support null
characters, and where regular expressions are used a lot, and so need
to be fast.

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019