<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/tools/perf/util/trace-event-parse.c, branch linux-2.6.34.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.34.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.34.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2010-07-05T18:21:54Z</updated>
<entry>
<title>perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR()</title>
<updated>2010-07-05T18:21:54Z</updated>
<author>
<name>Ian Munsie</name>
</author>
<published>2010-04-13T08:37:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=08959bab0e65a42ff0d10fde4982939b472a7a96'/>
<id>urn:sha1:08959bab0e65a42ff0d10fde4982939b472a7a96</id>
<content type='text'>
commit c05556421742eb47f80301767653a4bcb19de9de upstream.

Parsing an option from the command line with OPT_BOOLEAN on a
bool data type would not work on a big-endian machine due to the
manner in which the boolean was being cast into an int and
incremented. For example, running 'perf probe --list' on a
PowerPC machine would fail to properly set the list_events bool
and would therefore print out the usage information and
terminate.

This patch makes OPT_BOOLEAN work as expected with a bool
datatype. For cases where the original OPT_BOOLEAN was
intentionally being used to increment an int each time it was
passed in on the command line, this patch introduces OPT_INCR
with the old behaviour of OPT_BOOLEAN (the verbose variable is
currently the only such example of this).

I have reviewed every use of OPT_BOOLEAN to verify that a true
C99 bool was passed. Where integers were used, I verified that
they were only being used for boolean logic and changed them to
bools to ensure that they would not be mistakenly used as ints.
The major exception was the verbose variable which now uses
OPT_INCR instead of OPT_BOOLEAN.

Signed-off-by: Ian Munsie &lt;imunsie@au.ibm.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Cc: &lt;stable@kernel.org&gt;
Cc: Git development list &lt;git@vger.kernel.org&gt;
Cc: Ian Munsie &lt;imunsie@au1.ibm.com&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: KOSAKI Motohiro &lt;kosaki.motohiro@jp.fujitsu.com&gt;
Cc: Hitoshi Mitake &lt;mitake@dcl.info.waseda.ac.jp&gt;
Cc: Rusty Russell &lt;rusty@rustcorp.com.au&gt;
Cc: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Cc: Eric B Munson &lt;ebmunson@us.ibm.com&gt;
Cc: Valdis.Kletnieks@vt.edu
Cc: WANG Cong &lt;amwang@redhat.com&gt;
Cc: Thiago Farina &lt;tfransosi@gmail.com&gt;
Cc: Masami Hiramatsu &lt;mhiramat@redhat.com&gt;
Cc: Xiao Guangrong &lt;xiaoguangrong@cn.fujitsu.com&gt;
Cc: Jaswinder Singh Rajput &lt;jaswinderrajput@gmail.com&gt;
Cc: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Cc: OGAWA Hirofumi &lt;hirofumi@mail.parknet.co.jp&gt;
Cc: Mike Galbraith &lt;efault@gmx.de&gt;
Cc: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: Anton Blanchard &lt;anton@samba.org&gt;
Cc: John Kacur &lt;jkacur@redhat.com&gt;
Cc: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Cc: Steven Rostedt &lt;rostedt@goodmis.org&gt;
LKML-Reference: &lt;1271147857-11604-1-git-send-email-imunsie@au.ibm.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>perf: Fix static strings treated like dynamic ones</title>
<updated>2010-05-11T07:14:24Z</updated>
<author>
<name>Frederic Weisbecker</name>
</author>
<published>2010-05-05T20:07:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=de068ec048f807d4f62b7dda100c23a1365f086f'/>
<id>urn:sha1:de068ec048f807d4f62b7dda100c23a1365f086f</id>
<content type='text'>
The raw_field_ptr() helper, used to retrieve the address of a field
inside a trace event, treats every strings as if they were dynamic
ie: having a secondary level of indirection to retrieve their
contents.

FIELD_IS_STRING doesn't mean FIELD_IS_DYNAMIC, we only need to
compute the secondary dereference for the latter case.

This fixes perf sched segfaults, bad cmdline report and may be
some other bugs.

Reported-by: Jason Baron &lt;jbaron@redhat.com&gt;
Reported-by: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Signed-off-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Tom Zanussi &lt;tzanussi@gmail.com&gt;
</content>
</entry>
<entry>
<title>perf/scripts: Move common code out of Perl-specific files</title>
<updated>2010-02-23T19:37:29Z</updated>
<author>
<name>Tom Zanussi</name>
</author>
<published>2010-01-27T08:27:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7397d80ddde8eef3b1dce6c29e0c53bd322ef824'/>
<id>urn:sha1:7397d80ddde8eef3b1dce6c29e0c53bd322ef824</id>
<content type='text'>
This stuff is needed by all scripting engines; move it from the Perl
engine source to a more common place.

Signed-off-by: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Steven Rostedt &lt;rostedt@goodmis.org&gt;
Cc: Keiichi KII &lt;k-keiichi@bx.jp.nec.com&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
LKML-Reference: &lt;1264580883-15324-4-git-send-email-tzanussi@gmail.com&gt;
Signed-off-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
</content>
</entry>
<entry>
<title>perf tools: Add __data_loc support</title>
<updated>2010-01-31T07:27:52Z</updated>
<author>
<name>Hitoshi Mitake</name>
</author>
<published>2010-01-30T11:43:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=86d8d29634de4464d568e7c335c0da6cba64e8ab'/>
<id>urn:sha1:86d8d29634de4464d568e7c335c0da6cba64e8ab</id>
<content type='text'>
This patch is required to test the next patch for perf lock.

At 064739bc4b3d7f424b2f25547e6611bcf0132415 ,
support for the modifier "__data_loc" of format is added.

But, when I wanted to parse format of lock_acquired (or some
event else), raw_field_ptr() did not returned correct pointer.

So I modified raw_field_ptr() like this patch. Then
raw_field_ptr() works well.

Signed-off-by: Hitoshi Mitake &lt;mitake@dcl.info.waseda.ac.jp&gt;
Acked-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: Steven Rostedt &lt;srostedt@redhat.com&gt;
LKML-Reference: &lt;1264851813-8413-2-git-send-email-mitake@dcl.info.waseda.ac.jp&gt;
[ v3: fixed minor stylistic detail ]
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf tools: Correct size given to memset</title>
<updated>2009-12-10T07:30:26Z</updated>
<author>
<name>Julia Lawall</name>
</author>
<published>2009-12-09T19:26:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5660ce34241ab204bf78fbcaa5e09318c2748d37'/>
<id>urn:sha1:5660ce34241ab204bf78fbcaa5e09318c2748d37</id>
<content type='text'>
Memset should be given the size of the structure, not the size
of the pointer.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// &lt;smpl&gt;
@@
type T;
T *x;
expression E;
@@

memset(x, E, sizeof(
+ *
 x))
// &lt;/smpl&gt;

Signed-off-by: Julia Lawall &lt;julia@diku.dk&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
LKML-Reference: &lt;Pine.LNX.4.64.0912092026000.1870@ask.diku.dk&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf tools: Misc small fixes</title>
<updated>2009-12-06T17:15:02Z</updated>
<author>
<name>OGAWA Hirofumi</name>
</author>
<published>2009-12-06T11:10:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7691b1ec2e4a8d4bd88dcf88b29792399ebe1c91'/>
<id>urn:sha1:7691b1ec2e4a8d4bd88dcf88b29792399ebe1c91</id>
<content type='text'>
- util/header.c
	"len" is aligned to 64. So, it tries to write the out of
	long_name buffer.

	So, this use "zero_buf" to write aligned area.

- util/trace-event-read.c
	"size" is not including nul byte. So, this allocates it, and set '\0'.

- util/trace-event-parse.c
	It needs parens to calc correct size.

Signed-off-by: OGAWA Hirofumi &lt;hirofumi@mail.parknet.co.jp&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
LKML-Reference: &lt;87d42s8iiu.fsf_-_@devron.myhome.or.jp&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf trace: Add interface to access perf data from Perl handlers</title>
<updated>2009-11-28T09:04:27Z</updated>
<author>
<name>Tom Zanussi</name>
</author>
<published>2009-11-25T07:15:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d1b93772be78486397693fc39d3ddea3fda90105'/>
<id>urn:sha1:d1b93772be78486397693fc39d3ddea3fda90105</id>
<content type='text'>
The Perl scripting support for perf trace allows most of a trace
event's data to be accessed directly as handler arguments, but
not all of it e.g. the less common fields aren't passed in.  To
give scripts access to the other fields and/or any other data or
metadata in the main perf executable that might be useful, a way
to access the C data in perf from Perl is needed; this patch
uses the Perl XS facility to do it for the common_xxx event
fields not passed to handler functions.

Context.pm exports three functions to Perl scripts that access
fields for the current event by calling back into perf:
common_pc(), common_flags() and common_lock_depth().  Support
for common_flags() field values was added to Core.pm and a
script used to sanity check these and other basic scripting
features, check-perf-trace.pl, was also added.

Signed-off-by: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: fweisbec@gmail.com
Cc: rostedt@goodmis.org
Cc: anton@samba.org
Cc: hch@infradead.org
LKML-Reference: &lt;1259133352-23685-6-git-send-email-tzanussi@gmail.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf trace: Add Perl scripting support</title>
<updated>2009-11-28T09:04:26Z</updated>
<author>
<name>Tom Zanussi</name>
</author>
<published>2009-11-25T07:15:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=16c632de64a74644a46e7636db26b2cfb530ca13'/>
<id>urn:sha1:16c632de64a74644a46e7636db26b2cfb530ca13</id>
<content type='text'>
Implement trace_scripting_ops to make Perl a supported perf
trace scripting language.

Additionally adds code that allows Perl trace scripts to access
the 'flag' and 'symbolic' (__print_flags(), __print_symbolic())
field information parsed from the trace format files.

Also adds the Perl implementation of the generate_script()
trace_scripting_op, which creates a ready-to-run perf trace Perl
script based on existing trace data.  Scripts generated by this
implementation print out all the fields for each event mentioned
in perf.data (and will detect and generate the proper scripting
code for 'flag' and 'symbolic' fields), and will additionally
generate handlers for the special 'trace_unhandled',
'trace_begin' and 'trace_end' handlers.  Script authors can
simply remove the printing code to implement their own custom
event handling.

Signed-off-by: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: fweisbec@gmail.com
Cc: rostedt@goodmis.org
Cc: anton@samba.org
Cc: hch@infradead.org
LKML-Reference: &lt;1259133352-23685-4-git-send-email-tzanussi@gmail.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf trace: Add flag/symbolic format_flags</title>
<updated>2009-11-28T09:04:25Z</updated>
<author>
<name>Tom Zanussi</name>
</author>
<published>2009-11-25T07:15:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=eb9a42caa7a926beb935a22bc59d981b35f0b652'/>
<id>urn:sha1:eb9a42caa7a926beb935a22bc59d981b35f0b652</id>
<content type='text'>
It's useful to know whether a field is a flag or symbolic field
for e.g. when generating scripts - it allows us to translate
those fields specially rather than literally as plain numeric
values.

Signed-off-by: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: fweisbec@gmail.com
Cc: rostedt@goodmis.org
Cc: anton@samba.org
Cc: hch@infradead.org
LKML-Reference: &lt;1259133352-23685-3-git-send-email-tzanussi@gmail.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>perf tools: Add 'signed' flag setting back into trace-event-parse.c</title>
<updated>2009-11-25T08:06:09Z</updated>
<author>
<name>Tom Zanussi</name>
</author>
<published>2009-11-25T07:14:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0d0bea5ea4a0e91feff22ac5e32e14ff3a682247'/>
<id>urn:sha1:0d0bea5ea4a0e91feff22ac5e32e14ff3a682247</id>
<content type='text'>
Commit 13999e59343b042b0807be2df6ae5895d29782a0 (perf tools:
Handle the case with and without the "signed" trace field)
removed code to set the FIELD_IS_SIGNED flag that was originally
added by commit 26a50744b21fff65bd754874072857bee8967f4d
(tracing/events: Add 'signed' field to format files).

This adds it back.

Signed-off-by: Tom Zanussi &lt;tzanussi@gmail.com&gt;
Cc: Steven Rostedt &lt;rostedt@goodmis.org&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Mike Galbraith &lt;efault@gmx.de&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
LKML-Reference: &lt;1259133299-23594-2-git-send-email-tzanussi@gmail.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
</feed>
