From: Julia Lawall <julia.lawall@lip6.fr>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Michal Marek <michal.lkml@markovi.net>,
Nicolas Palix <nicolas.palix@imag.fr>,
cocci@systeme.lip6.fr
Subject: Re: [PATCH] coccinelle: flags.cocci: reorganize patterns to improve efficiency
Date: Wed, 15 Nov 2017 22:55:09 +0100 (CET) [thread overview]
Message-ID: <alpine.DEB.2.20.1711152253270.2134@hadrien> (raw)
In-Reply-To: <CAK7LNAT5_RriY7yORFoWeAd5354HVmU2xXWZTvmuk3YHO+MxFA@mail.gmail.com>
On Thu, 16 Nov 2017, Masahiro Yamada wrote:
> Hi Julia,
>
>
> 2017-11-15 23:51 GMT+09:00 Julia Lawall <julia.lawall@lip6.fr>:
> >
> >
> > On Wed, 15 Nov 2017, Masahiro Yamada wrote:
> >
> >> Hi Julia,
> >>
> >>
> >> 2017-11-13 1:08 GMT+09:00 Julia Lawall <julia.lawall@lip6.fr>:
> >> > An initial rule just matching a function call makes it possible to focus
> >> > on one all at a time, which improves performance in complex functions with
> >> > multiple locking calls. Using a constraint expression lock2 != pre.lock1;
> >> > makes it possible to eliminate the double matching of the lock, lock
> >> > sequence.
> >> >
> >> > Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
> >>
> >>
> >> If I apply this patch, locks/flags.cocci does not work for me.
> >>
> >>
> >> $ make coccicheck COCCI=scripts/coccinelle/locks/flags.cocci
> >> MODE=report DEBUG_FILE=log.txt
> >>
> >> Please check for false positives in the output before submitting a patch.
> >> When using "patch" mode, carefully review the patch before submitting it.
> >>
> >> 607 610
> >> coccicheck failed
> >> $ cat log.txt
> >> /usr/bin/spatch -D report --no-show-diff --very-quiet --cocci-file
> >> scripts/coccinelle/locks/flags.cocci --no-includes --include-headers
> >> --dir . -I ./arch/x86/include -I ./arch/x86/include/generated -I
> >> ./include -I ./arch/x86/include/uapi -I
> >> ./arch/x86/include/generated/uapi -I ./include/uapi -I
> >> ./include/generated/uapi --include ./include/linux/kconfig.h --jobs 8
> >> --chunksize 1
> >> Fatal error: exception Failure("meta: parse error: \n = File
> >> \"scripts/coccinelle/locks/flags.cocci\", line 29, column 20, charpos
> >> = 607\n around = 'pre', whole content = expression lock2 !=
> >> pre.lock1;\n")
> >>
> >>
> >>
> >> Could you check it?
> >
> > What version of Coccinelle do you have?
>
>
> I tried 1.0.4 and 1.0.6,
> but both failed.
For me, it also fails for 1.0.6. It should be OK for 1.0.7.
julia
>
>
> (1.0.4 is distribution version (/usr/bin/spatch) on Ubuntu 16.04LTS
>
>
>
> The output from 1.0.6 is a bit more readable,
> but the content is the same.
>
>
> meta: parse error:
> File "scripts/coccinelle/locks/flags.cocci", line 29, column 20, charpos = 607
> around = 'pre',
> whole content = expression lock2 != pre.lock1;
>
>
>
> --
> Best Regards
> Masahiro Yamada
>
next prev parent reply other threads:[~2017-11-15 21:55 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-12 16:08 [PATCH] coccinelle: flags.cocci: reorganize patterns to improve efficiency Julia Lawall
2017-11-15 14:46 ` Masahiro Yamada
2017-11-15 14:51 ` Julia Lawall
2017-11-15 15:26 ` Masahiro Yamada
2017-11-15 15:29 ` Julia Lawall
2017-11-15 21:55 ` Julia Lawall [this message]
2017-11-15 22:02 ` Joe Perches
2017-11-16 0:02 ` Masahiro Yamada
2017-11-16 7:31 ` Julia Lawall
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.2.20.1711152253270.2134@hadrien \
--to=julia.lawall@lip6.fr \
--cc=cocci@systeme.lip6.fr \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.lkml@markovi.net \
--cc=nicolas.palix@imag.fr \
--cc=yamada.masahiro@socionext.com \
/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