From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS22989 209.51.188.0/24 X-Spam-Status: No, score=-3.8 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 16C151F8C6 for ; Mon, 21 Jun 2021 21:09:39 +0000 (UTC) Received: from localhost ([::1]:40698 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lvRAn-0006o4-UR for normalperson@yhbt.net; Mon, 21 Jun 2021 17:09:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52722) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lvRAj-0006nW-HP for bug-gnulib@gnu.org; Mon, 21 Jun 2021 17:09:33 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:35150) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lvRAh-0007Sc-5X for bug-gnulib@gnu.org; Mon, 21 Jun 2021 17:09:33 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 720E7160113; Mon, 21 Jun 2021 14:09:28 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id jkbRJFtSuP9h; Mon, 21 Jun 2021 14:09:27 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 8865216011B; Mon, 21 Jun 2021 14:09:27 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id k-rfSYLO0GIy; Mon, 21 Jun 2021 14:09:27 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 5F9D8160113; Mon, 21 Jun 2021 14:09:27 -0700 (PDT) Subject: Re: [PATCH] regex: fix match with possessive quantifier To: "Dmitry V. Levin" , Egor Ignatov References: <20210526090819.7482-1-egori@altlinux.org> <20210606214502.GA16155@altlinux.org> From: Paul Eggert Organization: UCLA Computer Science Department Message-ID: <32c7255e-2e0d-2671-1641-2d02b13548c0@cs.ucla.edu> Date: Mon, 21 Jun 2021 14:09:27 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20210606214502.GA16155@altlinux.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=131.179.128.68; envelope-from=eggert@cs.ucla.edu; helo=zimbra.cs.ucla.edu X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: bug-gnulib@gnu.org Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" On 6/6/21 2:45 PM, Dmitry V. Levin wrote: > I've applied it now, and the following follow-up patch: These recently-installed patches fail for me, which indicates that the patches aren't correct. Could you please fix this? The test failure is causing 'make check' to fail for GNU grep. I tested on Ubuntu 21.04 x86-64 (with its packaged GCC 10.3.0-1ubuntu1), as follows: ./gnulib-tool --create-testdir --dir foo regex cd foo ./configure CFLAGS='-g3 -O2 -fsanitize=undefined' make check foo/gltests/test-regex.log contains: regex_internal.c:1317:7: runtime error: execution reached an unreachable program point FAIL test-regex (exit status: 1) The failing line is here: DEBUG_ASSERT (set->elems[idx - 1] < elem); I got a similar failure when I configured this way instead: ./configure CFLAGS='-g3 -O2 -DDEBUG' the only difference being a different diagnostic in test-regex.log: test-regex: regex_internal.c:1317: re_node_set_insert: Assertion `set->elems[idx - 1] < elem' failed. FAIL test-regex (exit status: 134) The problem is not limited to Ubuntu, as I got a similar failure on Fedora 34 with its packaged GCC 11.1.1 20210531 (Red Hat 11.1.1-3).