cocci.inria.fr archive mirror
 help / color / mirror / Atom feed
From: Markus Elfring <Markus.Elfring@web.de>
To: Julia Lawall <julia.lawall@lip6.fr>
Cc: Coccinelle <cocci@systeme.lip6.fr>
Subject: Re: [Cocci] Checking uniqueness for source code positions during SmPL data processing
Date: Mon, 22 Apr 2019 10:55:31 +0200	[thread overview]
Message-ID: <4d1dbbfe-5d37-7938-6cf3-35f3db8d745b@web.de> (raw)
In-Reply-To: <alpine.DEB.2.21.1904220953540.3142@hadrien>

> I'm not going to debug anything that involves external tools,
> ie your database.

* Will such a restriction become interesting also for further clarifications?

* Did you notice that the script variant “list_duplicate_statement_pairs_from_if_branches5.cocci”
  is working only by a simple combination of SmPL and Python code
  (without an extra dependency on the software “SQLAlchemy”)?
  The desired data should be imported into an ordinary Python dictionary here.


> Note however that by converting from * to printing, you have converted the
> ...s in your searching rule from "exists" to "forall" as the quantifier
> over the paths.

Thanks for this reminder of consequences around the asterisk functionality
and SmPL ellipses.


> You may want to put exists in the header of the searching rule.

I can try this setting also out.

Would you like to clarify the following test result?

elfring@Sonne:~/Projekte/Linux/next-patched> time spatch ~/Projekte/Coccinelle/janitor/list_duplicate_statement_pairs_from_if_branches6.cocci drivers/media/dvb-frontends/stv0297.c
…
statement1|statement2|"function name"|"source file"|incidence
dprintk ( "%s: readreg error (reg == 0x%02x, ret == %i)\n" , __func__ , reg , ret ) ;|return - 1 ;|stv0297_readreg|drivers/media/dvb-frontends/stv0297.c|3
dprintk ( "%s: readreg error (reg == 0x%02x, ret == %i)\n" , __func__ , reg1 , ret ) ;|return - 1 ;|stv0297_readregs|drivers/media/dvb-frontends/stv0297.c|3

real	0m0,272s
user	0m0,219s
sys	0m0,052s


Where does the added number come from for the identifier “reg1”?

Regards,
Markus
_______________________________________________
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci

  reply	other threads:[~2019-04-22  8:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-22  7:49 [Cocci] Checking uniqueness for source code positions during SmPL data processing Markus Elfring
2019-04-22  7:55 ` Julia Lawall
2019-04-22  8:55   ` Markus Elfring [this message]
2019-04-22  9:05     ` Julia Lawall
2019-04-22  9:26       ` Markus Elfring

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=4d1dbbfe-5d37-7938-6cf3-35f3db8d745b@web.de \
    --to=markus.elfring@web.de \
    --cc=cocci@systeme.lip6.fr \
    --cc=julia.lawall@lip6.fr \
    /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 NNTP newsgroup(s).