bug-gnulib@gnu.org mirror (unofficial)
 help / color / mirror / Atom feed
From: Sam James <sam@gentoo.org>
To: "Arsen Arsenović" <arsen@aarsen.me>, "Paul Eggert" <eggert@cs.ucla.edu>
Cc: arnold@skeeve.com, concord@gentoo.org, bug-gawk@gnu.org,
	Gnulib bugs <bug-gnulib@gnu.org>
Subject: Re: Clang-built Gawk 5.2.1 regex oddity
Date: Fri, 13 Jan 2023 07:03:52 +0000	[thread overview]
Message-ID: <BB0B3C13-EE38-4828-98D7-2D36040F7DCA@gentoo.org> (raw)
In-Reply-To: <87bkncy3vl.fsf@aarsen.me>

[-- Attachment #1: Type: text/plain, Size: 1126 bytes --]



> On 5 Jan 2023, at 23:06, Arsen Arsenović <arsen@aarsen.me> wrote:
> 
> Hi,
> 
> Paul Eggert <eggert@cs.ucla.edu> writes:
> 
>> This is a serious bug in Clang: it generates incorrect machine code.
>> 
>> The code that Clang generates for the following (gawk/support/dfa.c lines
>> 1141-1143):
>> 
>>    ((dfa->syntax.dfaopts & DFA_CONFUSING_BRACKETS_ERROR
>>      ? dfaerror : dfawarn)
>>     (_("character class syntax is [[:space:]], not [:space:]")));
>> 
>> is immediately followed by the code generated for the following
>> (gawk/support/dfa.c line 1015):
>> 
>>                    dfaerror (_("invalid character class"));
>> 
>> and this is incorrect because the two source code regions are not connected
>> with each other.
> 
> This is now fixed in Clang:
> https://reviews.llvm.org/rGcf8fd210a35c8e93136cb8edc5c6a2e818dc1b1d

This is not in 15.0.7 and there won't be any further 15.x releases as there's
an ABI break caused by it. We've backported it in Gentoo but others may not.

It will be in 16.x.

I think gnulib should probably make that #define change for Clang < 16.



[-- Attachment #2: Message signed with OpenPGP --]
[-- Type: application/pgp-signature, Size: 358 bytes --]

      parent reply	other threads:[~2023-01-13  7:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20221230000119.hyui6umnspuyzqum@bubbles>
     [not found] ` <202212300913.2BU9DV6V030160@freefriends.org>
     [not found]   ` <6DADB0FC-87EE-4028-91DF-C93A968A8982@gentoo.org>
2023-01-01 19:06     ` Clang-built Gawk 5.2.1 regex oddity arnold
2023-01-02  6:10       ` Paul Eggert
2023-01-03  2:14         ` Sam James
2023-01-03  2:43           ` Sam James
2023-01-05 23:06         ` Arsen Arsenović
2023-01-06 12:21           ` arnold
2023-01-13  7:03           ` Sam James [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://lists.gnu.org/mailman/listinfo/bug-gnulib

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BB0B3C13-EE38-4828-98D7-2D36040F7DCA@gentoo.org \
    --to=sam@gentoo.org \
    --cc=arnold@skeeve.com \
    --cc=arsen@aarsen.me \
    --cc=bug-gawk@gnu.org \
    --cc=bug-gnulib@gnu.org \
    --cc=concord@gentoo.org \
    --cc=eggert@cs.ucla.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).