Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp582977ybn; Wed, 25 Sep 2019 04:42:37 -0700 (PDT) X-Google-Smtp-Source: APXvYqyW/BtpsPowgoOUtlB6cTuQT5/ZHhyLu9HORLysWjDo+uLyu6JW9kO11ICH92PoHTElTkDx X-Received: by 2002:a2e:8558:: with SMTP id u24mr6047405ljj.191.1569411757184; Wed, 25 Sep 2019 04:42:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569411757; cv=none; d=google.com; s=arc-20160816; b=WXED3JbS9lAYBlic/O40ZZsyQEOlZIMEW66/fQJSufvZDAEjennqYagK8TaBsi+uIn ZcksOQDVcws36k44Fr83jFGMq1D1OnM/Yq9x+NnDr9t0IUw0VDaLdhQJd/YYed8Ihca5 ZS5k/0toz+qk//22Q2R9DpMZ9RpacsfbTXvNqeCnEBU2Pwmien7ugCQiu/XfXCWagIwz YGwZU8rY8RPmLi6E/gQ9UD3X+nv150tEdRhusQDDyvoeJ/8lpLwgM3353Ne6h5kCm8gk 9QSSW15ZrNFxpKw8Wn6IFxcE2D9M+XnuxEJIs86N6TsrKwgJZUNihOWwV3iUE2I3Tzpb S6Ww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=OzEauiKzs5TUo3H8T9Cb11zn4jhjc8YS2cm34loDntE=; b=HFU2peefJHWTGz3AtGF1w/rbXg9K72Vt4J+UDMJ9eLvwYWiUpcXt8BKdiaGQZvCv6C HqXmIVRKXcCV0eK1dpcz6Vrxrt7yWOZXKzRs1+k9FQoe90wNdl6PgoHawdYBOQMOqJlw JQ2VAOtIDTtQrGkVsWsNMhYIWgELjg8l86V4hAE9mKz++anN1CvJkNJIqQorn/HJof7B 5SZ8pgIHKybL+mWiyJj5Lg7PDQO/tBDb2RdQewnb7vIxL/VVrcXITNhi5JmJ15zNXUHR RZJEXeLzq2J8HXjYa6LEUvBH3y0+C6PGWz4Z1tT261sEkbE2eR7h4fpgSJ4/PpAhkuYW Ykrw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=fzuWAz6s; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id rh9si2462410ejb.102.2019.09.25.04.41.55; Wed, 25 Sep 2019 04:42:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=fzuWAz6s; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2501871AbfIWKbf (ORCPT + 99 others); Mon, 23 Sep 2019 06:31:35 -0400 Received: from mail.skyhub.de ([5.9.137.197]:57640 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2501858AbfIWKbf (ORCPT ); Mon, 23 Sep 2019 06:31:35 -0400 Received: from zn.tnic (p200300EC2F060400856443B6AC31000F.dip0.t-ipconnect.de [IPv6:2003:ec:2f06:400:8564:43b6:ac31:f]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 4760E1EC0819; Mon, 23 Sep 2019 12:31:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1569234694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=OzEauiKzs5TUo3H8T9Cb11zn4jhjc8YS2cm34loDntE=; b=fzuWAz6sVNZ2V/wJSH9QtjBbSVphnSwtEeh111PaD405rba1m7JxJHzrzV4DL3mgRSueUf cL5rmZ1xCbVlzrJvAFNzv/2cqs2Mh0QV/9GoYuJ06Nuo+OZe5spYZKIe+KfHgTay2HS7PG 4cZOEQmwi7nGLIR2X/HNe1iHGQC5E9o= Date: Mon, 23 Sep 2019 12:31:39 +0200 From: Borislav Petkov To: Alexander Kapshuk Cc: linux-kernel@vger.kernel.org, tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com, x86@kernel.org, kbuild test robot , Masami Hiramatsu Subject: Re: [PATCH RESEND] gen-insn-attr-x86.awk: Fix regexp warnings Message-ID: <20190923103139.GD15355@zn.tnic> References: <20190922083342.GO13569@xsang-OptiPlex-9020> <20190922150328.6722-1-alexander.kapshuk@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190922150328.6722-1-alexander.kapshuk@gmail.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org + Masami. On Sun, Sep 22, 2019 at 06:03:28PM +0300, Alexander Kapshuk wrote: > This patch fixes the regexp warnings shown below: Avoid having "This patch" or "This commit" in the commit message. It is tautologically useless. Also, do $ git grep 'This patch' Documentation/process for more details. > GEN /home/sasha/torvalds/tools/objtool/arch/x86/lib/inat-tables.c > awk: ../arch/x86/tools/gen-insn-attr-x86.awk:260: warning: regexp escape sequence `\:' is not a known regexp operator > awk: ../arch/x86/tools/gen-insn-attr-x86.awk:350: (FILENAME=../arch/x86/lib/x86-opcode-map.txt FNR=41) warning: regexp escape sequence `\&' is not a known regexp operator > > The ':' and '&' characters need not escaping when used in string constants > as part of regular expressions. I could use a reasoning here, as in, "gawk manual doesn't have those two characters in the list here: https://www.gnu.org/software/gawk/manual/html_node/Escape-Sequences.html" or so. > > [Test-run] > awk -f arch/x86/tools/gen-insn-attr-x86.awk \ > arch/x86/lib/x86-opcode-map.txt >../tmp/inat-tables.c > > diff arch/x86/lib/inat-tables.c ~/tmp/inat-tables.c; echo $? > 0 > > awk -f tools/arch/x86/tools/gen-insn-attr-x86.awk \ > tools/arch/x86/lib/x86-opcode-map.txt >../tmp/inat-tables.c > > diff tools/objtool/arch/x86/lib/inat-tables.c ~/tmp/inat-tables.c; echo $? > 0 No need for that - just say that diffing the output before and after shows no changes. > [Debugging output] > DBG:ext:(66&F2) > DBG:match(ext, ...):(66&F2) > DBG:match(..., lprefix3_expr):\((F2|!F3|66&F2)\) That is supposed to say what exactly? That it still does what it is expected to do? Leaving in the rest for Masami. Thx. > Signed-off-by: Alexander Kapshuk > Reported-by: kbuild test robot > --- > arch/x86/tools/gen-insn-attr-x86.awk | 4 ++-- > tools/arch/x86/tools/gen-insn-attr-x86.awk | 4 ++-- > 2 files changed, 4 insertions(+), 4 deletions(-) > > diff --git a/arch/x86/tools/gen-insn-attr-x86.awk b/arch/x86/tools/gen-insn-attr-x86.awk > index b02a36b2c14f..a42015b305f4 100644 > --- a/arch/x86/tools/gen-insn-attr-x86.awk > +++ b/arch/x86/tools/gen-insn-attr-x86.awk > @@ -69,7 +69,7 @@ BEGIN { > > lprefix1_expr = "\\((66|!F3)\\)" > lprefix2_expr = "\\(F3\\)" > - lprefix3_expr = "\\((F2|!F3|66\\&F2)\\)" > + lprefix3_expr = "\\((F2|!F3|66&F2)\\)" > lprefix_expr = "\\((66|F2|F3)\\)" > max_lprefix = 4 > > @@ -257,7 +257,7 @@ function convert_operands(count,opnd, i,j,imm,mod) > return add_flags(imm, mod) > } > > -/^[0-9a-f]+\:/ { > +/^[0-9a-f]+:/ { > if (NR == 1) > next > # get index > diff --git a/tools/arch/x86/tools/gen-insn-attr-x86.awk b/tools/arch/x86/tools/gen-insn-attr-x86.awk > index b02a36b2c14f..a42015b305f4 100644 > --- a/tools/arch/x86/tools/gen-insn-attr-x86.awk > +++ b/tools/arch/x86/tools/gen-insn-attr-x86.awk > @@ -69,7 +69,7 @@ BEGIN { > > lprefix1_expr = "\\((66|!F3)\\)" > lprefix2_expr = "\\(F3\\)" > - lprefix3_expr = "\\((F2|!F3|66\\&F2)\\)" > + lprefix3_expr = "\\((F2|!F3|66&F2)\\)" > lprefix_expr = "\\((66|F2|F3)\\)" > max_lprefix = 4 > > @@ -257,7 +257,7 @@ function convert_operands(count,opnd, i,j,imm,mod) > return add_flags(imm, mod) > } > > -/^[0-9a-f]+\:/ { > +/^[0-9a-f]+:/ { > if (NR == 1) > next > # get index > -- > 2.23.0 > -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette