From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752097AbdJETbD (ORCPT ); Thu, 5 Oct 2017 15:31:03 -0400 Received: from smtprelay0155.hostedemail.com ([216.40.44.155]:52172 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751886AbdJETbB (ORCPT ); Thu, 5 Oct 2017 15:31:01 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::::::::::,RULES_HIT:41:355:379:541:599:800:960:973:982:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1542:1593:1594:1711:1730:1747:1777:1792:2198:2199:2393:2553:2559:2562:2693:2694:2828:3138:3139:3140:3141:3142:3354:3622:3653:3865:3866:3867:3868:3870:3871:3872:3873:3874:4321:5007:6119:6742:7903:7974:9391:10004:10400:10848:11232:11658:11783:11914:12043:12050:12262:12438:12555:12663:12679:12740:12895:13149:13230:13439:13894:14181:14659:14721:21080:21325:21365:21434:21451:21611:21627:30054:30060:30070:30090:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:1,LUA_SUMMARY:none X-HE-Tag: tiger92_7ce28dadac510 X-Filterd-Recvd-Size: 3440 Message-ID: <1507231856.4434.41.camel@perches.com> Subject: Re: [PATCH] coccinelle: api: detect duplicate chip data arrays From: Joe Perches To: Julia Lawall Cc: Masahiro Yamada , Liam Breck , Sebastian Reichel , Pali =?ISO-8859-1?Q?Roh=E1r?= , Linux PM mailing list , kernel-janitors@vger.kernel.org, Gilles Muller , Nicolas Palix , Michal Marek , cocci@systeme.lip6.fr, Linux Kernel Mailing List , kbuild test robot Date: Thu, 05 Oct 2017 12:30:56 -0700 In-Reply-To: References: <1506861768-5734-1-git-send-email-Julia.Lawall@lip6.fr> <1507230959.4434.39.camel@perches.com> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.22.6-1ubuntu1 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2017-10-05 at 21:19 +0200, Julia Lawall wrote: > On Thu, 5 Oct 2017, Joe Perches wrote: > > On Thu, 2017-10-05 at 21:13 +0200, Julia Lawall wrote: > > > On Fri, 6 Oct 2017, Masahiro Yamada wrote: > > > > 2017-10-01 21:42 GMT+09:00 Julia Lawall : > > > > > This semantic patch detects duplicate arrays declared using BQ27XXX_DATA > > > > > within a single structure. It is currently specific to the file > > > > > drivers/power/supply/bq27xxx_battery.c. > > > > > Signed-off-by: Julia Lawall > > > > Applied to linux-kbuild/misc. > > > Thanks for picking it up. > > If it is specific to one file, why not just run it > > and post the resultant patch? Why have it in tree? > I guess that they anticipate that the data may change in the future? Aren't you the script author Julia? Who is the "they"? I think having a script for a single file unnecessary. btw: spatch 1.7 doesn't seem to have a tag in git >>From the script: // Requires: 1.0.7 Assuming this is correct, then this doesn't even run today except maybe on your system. $ git show commit 0bf53049e64295e8ddb625e853134f49568f4bc3 Merge: 446dc66f8b98 d599cc6a75e0 Author: julia Date:   Sun Oct 1 22:44:34 2017 +0200     Merge git+ssh://palace.lip6.fr/var/git/coccinelle $ When I build this, the version is 1.0.6 $ /usr/local/bin/spatch --version spatch version 1.0.6-00033-g23cca0a238c2 compiled with OCaml version 4.02.3 Flags passed to the configure script: [none] Python scripting support: yes Syntax of regular expresssions: PCRE > If id-utils is used, Coccinelle will completely ignore files that don't > contain BQ27XXX_DATA, so the rule will have essentially no performance > impact. If there is no indexing, it will only "grep" for BQ27XXX_DATA, > not actually parse the files that don't contain it. So there is not much > performance impact even in that case. I'm not sure that matters.