From owner-freebsd-current@FreeBSD.ORG Sat Jun 25 16:09:40 2011 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF8251065675 for ; Sat, 25 Jun 2011 16:09:40 +0000 (UTC) (envelope-from utisoft@gmail.com) Received: from mail-iw0-f182.google.com (mail-iw0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id A4E1C8FC08 for ; Sat, 25 Jun 2011 16:09:40 +0000 (UTC) Received: by iwr19 with SMTP id 19so4317931iwr.13 for ; Sat, 25 Jun 2011 09:09:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=kWiG04KHi5nbxbxB6oETMvKw3WYCh/GFfA3eEtNFetQ=; b=BN6ld47rUKwEWvMtEenuyPMorgqGCSSk7cvuCMiW3H/0M9SSfTe/M5oscJSj2Vkx9d LZCumEYiy4puU7xguYb/aWXW9TRg7miEx6fQIo9EKkIpvxGKaEpYZKRKL1piRClSnDRB LR/UhZOKHE9TeOQp9LemRcjJojhoAnuZV+4Fk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; b=VsCL4Dxg0vC07RDf/aoU5OvmVkEbSPK/ds+zJPro8um99y0LTJN+Z4Zu2oY2tNLGy+ WlKlWI25f8smh39607XSbQhhUSTO5KQq8w7Yyr37P4zNY5GNpx7De5Z9Ccfr+28BgUom bNK3U+wV/fG0OEQFT7PfdSDW9YkTl0RMyuE68= MIME-Version: 1.0 Received: by 10.231.167.197 with SMTP id r5mr3840014iby.70.1309016397396; Sat, 25 Jun 2011 08:39:57 -0700 (PDT) Sender: utisoft@gmail.com Received: by 10.231.49.193 with HTTP; Sat, 25 Jun 2011 08:39:56 -0700 (PDT) Received: by 10.231.49.193 with HTTP; Sat, 25 Jun 2011 08:39:56 -0700 (PDT) In-Reply-To: <4E05E7EC.9000902@FreeBSD.org> References: <4E05E7EC.9000902@FreeBSD.org> Date: Sat, 25 Jun 2011 16:39:56 +0100 X-Google-Sender-Auth: hMG8Q0jh040G9ExrUskqj-gU5UU Message-ID: From: Chris Rees To: Gabor Kovesdan Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: current@freebsd.org Subject: Re: [CFT] patch to replace the regex code X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Jun 2011 16:09:41 -0000 On 25 Jun 2011 15:08, "Gabor Kovesdan" wrote: > > Hi Folks, > > you may know that in the Summer of Code programme I'm working on replacing the old regex code with TRE, which is a BSD-licensed implementation. It supports wide characters, is POSIX-compliant and has a good performance compared to most of the open source implementations. Actually, I got mixed results. With sed, in the cases that I tested, the performance was more or less the same and in some few cases, TRE finished in half of the time. On the other hand, with grep sometimes it was significantly slower than the current regex code but grep has always been a complicated case. Forgive me if I'm patronizing, but is there any surprise that a POSIX NFA implementation is slower than grep's DFA? Chris