> let add_function f c =
> if not (List.mem f !relevant_functions)
> then
> begin
> let s = String.concat " "
> (
> (List.map String.lowercase_ascii
>(List.filter
> (function x ->
>Str.string_match
>
>> Thus I imagine that an other documentation format would be safer
>> and more helpful for the determination of a corresponding API
>> system property.
>
> Our script will remove '* ','\ n','\t' and so on from the comments in the
> function header
> and then merge them into one line,
* Would
> > We currently use the following Ocaml script to automatically
> > collect functions that need to be considered.
> >
> > @initialize:ocaml@
> > @@
> >
> > let relevant_str = "use of_node_put() on it when done"
>
> I suggest to reconsider this search pattern.
>
> The mentioned words are
> We currently use the following Ocaml script to automatically
> collect functions that need to be considered.
>
> @initialize:ocaml@
> @@
>
> let relevant_str = "use of_node_put() on it when done"
I suggest to reconsider this search pattern.
The mentioned words are distributed over text lines
> > 2, A general method.
> > We also try to get the list of functions to consider by writing a SmPL,
> > but this method is not feasible at present, because it is not easy to parse
> > the comment
> > header information of these functions.
>
> The situation was improved once more also for the
> 2, A general method.
> We also try to get the list of functions to consider by writing a SmPL,
> but this method is not feasible at present, because it is not easy to parse
> the comment
> header information of these functions.
The situation was improved once more also for the Coccinelle
> On the other hand, I don't know if the one that seemed to cause a crash
> really caused a crash. It was detected by syzkaller, and it is also
> possible that git bisect ended up at the wrong place.
Do you refer to any known bug report here?
> In any case, forgetting an of_node_put will
On Mon, 20 May 2019, Sasha Levin wrote:
> On Mon, May 20, 2019 at 11:52:37AM +0200, Julia Lawall wrote:
> >
> >
> > On Mon, 20 May 2019, Pavel Machek wrote:
> >
> > > Hi!
> > >
> > > > A semantic patch has no access to comments. The only thing I can see to
> > > > do is to use python to
On Mon, May 20, 2019 at 11:52:37AM +0200, Julia Lawall wrote:
On Mon, 20 May 2019, Pavel Machek wrote:
Hi!
> A semantic patch has no access to comments. The only thing I can see to
> do is to use python to interact with some external tools. For example,
> you could write some code to
On Mon, 20 May 2019, Pavel Machek wrote:
> Hi!
>
> > A semantic patch has no access to comments. The only thing I can see to
> > do is to use python to interact with some external tools. For example,
> > you could write some code to collect the comments in a file and the lines
> > on which
> $ spatch --tokens-c drivers/of/base.c 2>&1 | grep "Tag3 " | grep
> "of_node_put() on it when done." | awk -F " - " '{print $1}' | grep -o
> "of_[[:print:]]*"
This command example points some details out for further software development
considerations.
1. I find it questionable that
On Mon, 20 May 2019, Pavel Machek wrote:
> Hi!
>
> > A semantic patch has no access to comments. The only thing I can see to
> > do is to use python to interact with some external tools. For example,
> > you could write some code to collect the comments in a file and the lines
> > on which
Hi!
> A semantic patch has no access to comments. The only thing I can see to
> do is to use python to interact with some external tools. For example,
> you could write some code to collect the comments in a file and the lines
> on which they occur, and then get the comment that most closely
> A semantic patch has no access to comments.
Thanks for your acknowledgement of the current situation.
> The only thing I can see to do is to use python to interact with some
> external tools.
I see more software development possibilities.
* Advanced data processing for source code comments
> 1, A simple method.
> We did some experiments, and we could get the list of functions that need to
> be considered directly through this script:
>
> $ spatch --tokens-c drivers/of/base.c 2>&1 | grep "Tag3 " | grep
> "of_node_put() on it when done." | awk -F " - " '{print $1}' | grep -o
>
A semantic patch has no access to comments. The only thing I can see to
do is to use python to interact with some external tools. For example,
you could write some code to collect the comments in a file and the lines
on which they occur, and then get the comment that most closely precedes
the
> It's interesting to get the function list automatically.
I occasionally imported code data into list variables
or even database tables.
> I'll try to parse the drivers/of/base.c file based on comments like this
> "* Returns a node pointer with refcount incremented, use
> * of_node_put() on it
Hi Markus,
Thanks for the review.
> > The call to of_parse_phandle()/of_find_node_by_name() ... returns a node
> > pointer with refcount incremented thus it must be explicitly decremented
> > after the last usage.
> >
> > This SmPL is also looking for places where there is an of_node_put on
> >
> The call to of_parse_phandle()/of_find_node_by_name() ... returns a node
> pointer with refcount incremented thus it must be explicitly decremented
> after the last usage.
>
> This SmPL is also looking for places where there is an of_node_put on
> some path but not on others.
I suggest to
The call to of_parse_phandle()/of_find_node_by_name() ... returns a node
pointer with refcount incremented thus it must be explicitly decremented
after the last usage.
This SmPL is also looking for places where there is an of_node_put on
some path but not on others.
Suggested-by: Julia Lawall
> +/// Find missing of_node_put
> +///
> +// Confidence: Moderate
How much would you like to improve the situation around recurring software
development concerns for such source code analysis approaches?
> +virtual report
> +virtual org
I would interpret the provided SmPL code in the way that
On Fri, 15 Mar 2019, Wen Yang wrote:
> Looking for places where there is an of_node_put on some paths
> but not on others. This SmPL checks that there is a put of the
> same data elsewhere in the function, so perhaps that will
> alleviate the concern about puts where they are not needed,
>
Looking for places where there is an of_node_put on some paths
but not on others. This SmPL checks that there is a put of the
same data elsewhere in the function, so perhaps that will
alleviate the concern about puts where they are not needed,
while still making it possible to find the ones that
23 matches
Mail list logo