Hui Zhu | 24 Apr 13:42 2014
Picon

Call for Topics and Sponsors -- Workshop on Open Source Development Tools 2014 (i.e. HelloGCC Workshop)

*************************************************************************
Call for Topics and Sponsors

Workshop on Open Source Development Tools 2014 (i.e. HelloGCC Workshop)
Beijing, China
Sep. 13rd, 2014 (TBD)
HelloGCC Work Group (www.hellogcc.org)
*************************************************************************
Open Source Development Tools Workshop (i.e. HelloGCC Workshop) is
a meeting for open source software developers. You can share your
work, study and
learning experience of open source software development here. Our main
topics is open
source development tools.

The content of topics can be:
* GNU tool chains (gcc, gdb, binutils, etc)
* LLVM or other open source compilers
* other tools of open source development, debug and simulation

The form of topics can be:
* the introduction of your own work
* the introduction of your work did in the past
* tutorial, experience and etc
* other forms of presentation, such as lightning talk

If you have some topics, please contact us:
* send email to hellogcc <at> freelists.org (need to subscribe
http://www.freelists.org/list/hellogcc first)
* login into freenode IRC #hellogcc room
(Continue reading)

Christian Babeux | 22 Apr 18:27 2014

Announcing GSoC 2014 Accepted Students

We have had great applications for Google Summer of Code 2014! We had
much more applications than last year and had to make tough calls for
our final selection.

The time for proposals evaluation has officially ended and Google
announced the GSoC 2014 participants [1].

For GSoC 2014 we will have the following projects/students/mentors:

Project: Using the LTTng toolchain in cloud service monitoring
Student: Marios Evangelos Kogias
Mentor: Jérémie Galarneau (irc: jgalar)

Project: Clang plugin providing automatic application instrumentation
Student: Sandeep Chaudhary
Mentor: Christian Babeux (irc: cbab)

Thanks to all the students who have applied,

The LTTng GSoC Team.

[1] - https://www.google-melange.com/gsoc/org2/google/gsoc2014/lttng

_______________________________________________
lttng-dev mailing list
lttng-dev <at> lists.lttng.org
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Jesper Derehag | 18 Apr 23:55 2014
Picon

[PATCH v2 babeltrace] Added fallback for betoh/htobe if they do not exist

For older systems endian.h may not contain the betoh/htobe macros.
If they are missing, add them and make sure that any user of
htobe/betoh uses include/babeltrace/endian.h and not system endian.h

Signed-off-by: Jesper Derehag <jderehag <at> hotmail.com>
Tested-by: Jesper Derehag <jderehag <at> hotmail.com>
---
Fixed the commit author email to jderehag <at> hotmail.com

 formats/lttng-live/lttng-live-comm.c |  1 +
 include/babeltrace/endian.h          | 91 +++++++++++++++++++++++++++++++++++-
 2 files changed, 91 insertions(+), 1 deletion(-)

diff --git a/formats/lttng-live/lttng-live-comm.c b/formats/lttng-live/lttng-live-comm.c
index 9feb718..3aad981 100644
--- a/formats/lttng-live/lttng-live-comm.c
+++ b/formats/lttng-live/lttng-live-comm.c
 <at>  <at>  -50,6 +50,7  <at>  <at> 
 #include <babeltrace/ctf/events-internal.h>
 #include <formats/ctf/events-private.h>

+#include <babeltrace/endian.h>
 #include <babeltrace/compat/memstream.h>

 #include "lttng-live.h"
diff --git a/include/babeltrace/endian.h b/include/babeltrace/endian.h
index f15a44f..e39e599 100644
--- a/include/babeltrace/endian.h
+++ b/include/babeltrace/endian.h
 <at>  <at>  -47,7 +47,96  <at>  <at> 
(Continue reading)

Jesper Derehag | 18 Apr 23:48 2014
Picon

[PATCH babeltrace] Added fallback for betoh/htobe if they do not exist

From: Jesper Derehag <jesper.derehag <at> ericsson.com>

For older systems endian.h may not contain the betoh/htobe macros.
If they are missing, add them and make sure that any user of
htobe/betoh uses include/babeltrace/endian.h and not system endian.h

Signed-off-by: Jesper Derehag <jderehag <at> hotmail.com>
Tested-by: Jesper Derehag <jderehag <at> hotmail.com>
---
 formats/lttng-live/lttng-live-comm.c |  1 +
 include/babeltrace/endian.h          | 91 +++++++++++++++++++++++++++++++++++-
 2 files changed, 91 insertions(+), 1 deletion(-)

diff --git a/formats/lttng-live/lttng-live-comm.c b/formats/lttng-live/lttng-live-comm.c
index 9feb718..3aad981 100644
--- a/formats/lttng-live/lttng-live-comm.c
+++ b/formats/lttng-live/lttng-live-comm.c
 <at>  <at>  -50,6 +50,7  <at>  <at> 
 #include <babeltrace/ctf/events-internal.h>
 #include <formats/ctf/events-private.h>

+#include <babeltrace/endian.h>
 #include <babeltrace/compat/memstream.h>

 #include "lttng-live.h"
diff --git a/include/babeltrace/endian.h b/include/babeltrace/endian.h
index f15a44f..e39e599 100644
--- a/include/babeltrace/endian.h
+++ b/include/babeltrace/endian.h
 <at>  <at>  -47,7 +47,96  <at>  <at> 
(Continue reading)

Yao Qi | 18 Apr 12:07 2014

Access metadata via libbabeltrace

Hi,
I have a metadata like this:

event {
        name = "register";
        id = 0;
        fields := struct {
                ascii contents[440];
        };
};

and I can get the length of the array if I have an event,

	  const struct bt_definition *scope
	    = bt_ctf_get_top_level_scope (event,
					  BT_EVENT_FIELDS);
	  const struct bt_definition *array
	    = bt_ctf_get_field (event, scope, "contents");

	  block_size
	    = bt_ctf_get_array_len (bt_ctf_get_decl_from_def (array));

block_size is what I want.  However, how can I get the array length
without an event?  I looked into babeltrace source for a while, but
don't see any API on metadata.

--

-- 
Yao (齐尧)

_______________________________________________
(Continue reading)

Mathieu Desnoyers | 16 Apr 22:56 2014

[PATCH lttng-modules] Statedump event for block devices

From: Houssem Daoud <houssemmh <at> gmail.com>

[ Edited by Mathieu Desnoyers. ]
Signed-off-by: Houssem Daoud <houssemmh <at> gmail.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers <at> efficios.com>
---
 README                                             |    2 +
 .../events/lttng-module/lttng-statedump.h          |   16 +++
 lttng-statedump-impl.c                             |   46 ++++++++
 wrapper/genhd.h                                    |  113 ++++++++++++++++++++
 4 files changed, 177 insertions(+)
 create mode 100644 wrapper/genhd.h

diff --git a/README b/README
index 9aa5b93..119bfa8 100644
--- a/README
+++ b/README
 <at>  <at>  -83,6 +83,8  <at>  <at>  CONFIG_KPROBES:
 CONFIG_KRETPROBES:
             Dynamic function entry/return probe.
                lttng enable-event -k --function ...
+CONFIG_KALLSYMS_ALL:
+            State dump of mapping between block device number and name.

 
 * Note about Perf PMU counters support
diff --git a/instrumentation/events/lttng-module/lttng-statedump.h b/instrumentation/events/lttng-module/lttng-statedump.h
index e4c86d6..efd22d7 100644
--- a/instrumentation/events/lttng-module/lttng-statedump.h
+++ b/instrumentation/events/lttng-module/lttng-statedump.h
(Continue reading)

Jessica Foest | 16 Apr 22:31 2014
Picon

babeltrace

Hi all

i know that the default output format of babeltrace is text .
what are the others output format supported by babeltrace ?

in my case , i need to convert the CTF log file of lttng to a CSV file , did tou have any idea about how can i do it ?

thanks
_______________________________________________
lttng-dev mailing list
lttng-dev <at> lists.lttng.org
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Christian Babeux | 16 Apr 18:26 2014

[PATCH] Clarify limitations of the --syscall flag with enable-event command

Signed-off-by: Christian Babeux <christian.babeux <at> efficios.com>
---
 doc/man/lttng.1 | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/doc/man/lttng.1 b/doc/man/lttng.1
index 972f71c..9882083 100644
--- a/doc/man/lttng.1
+++ b/doc/man/lttng.1
 <at>  <at>  -541,7 +541,9  <at>  <at>  Dynamic function entry/return probe. Addr and offset can be octal
 .BR "\-\-syscall"
 System call event. Enabling syscalls tracing (kernel tracer), you will
 not be able to disable them with disable-event. This is a known
-limitation. You can disable the entire channel to do the trick.
+limitation. You can disable the entire channel to do the trick. Also note
+that per-syscall selection is not supported yet. Use with "-a" to enable
+all syscalls.
 .TP
 .BR "\-\-filter 'expression'"
 Set a filter on a newly enabled event. Filter expression on event
--

-- 
1.9.2
Sébastien Barthélémy | 16 Apr 18:22 2014

memory usage depending on number and size of subbuffers

Hi all,

LTTng uses more memory than I expected. On the simple experiment below one can see that the "cached" memory increases by

subbuf_size*num_cpu*(num_subbuf+1)

That's not a big deal, but I did not expect the "+1".

Does somebody know where it comes from?


-- Regards, Sebastien


12M == 2M*2*(2+1)
24M == 4M*2*(2+1)
20M == 2M*2*(4+1)
40M == 4M*2*(4+1)

# grep processor /proc/cpuinfo
processor       : 0
processor       : 1

# lttng create
Session auto-20140416-180246 created.
Traces will be written in /root/lttng-traces/auto-20140416-180246

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        670        332          0         22        250
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng enable-channel channel0 --num-subbuf 2 --subbuf-size 2M -u
UST channel channel0 enabled for session auto-20140416-180246

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        682        320          0         22        262
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng destroy
Session auto-20140416-180246 destroyed

# lttng create
Session auto-20140416-180317 created.
Traces will be written in /root/lttng-traces/auto-20140416-180317

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        670        332          0         22        250
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng enable-channel channel0 --num-subbuf 2 --subbuf-size 4M -u
UST channel channel0 enabled for session auto-20140416-180317

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        694        307          0         22        274
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng destroy
Session auto-20140416-180317 destroyed

# lttng create
Session auto-20140416-180339 created.
Traces will be written in /root/lttng-traces/auto-20140416-180339

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        670        332          0         22        250
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng enable-channel channel0 --num-subbuf 4 --subbuf-size 2M -u
UST channel channel0 enabled for session auto-20140416-180339

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        690        311          0         22        270
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng destroy
Session auto-20140416-180339 destroyed

# lttng create
Session auto-20140416-180406 created.
Traces will be written in /root/lttng-traces/auto-20140416-180406

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        670        332          0         22        250
-/+ buffers/cache:        397        605
Swap:            0          0          0

# lttng enable-channel channel0 --num-subbuf 4 --subbuf-size 4M -u
UST channel channel0 enabled for session auto-20140416-180406

# free -m
             total       used       free     shared    buffers     cached
Mem:          1002        710        292          0         22        290
-/+ buffers/cache:        397        605

_______________________________________________
lttng-dev mailing list
lttng-dev <at> lists.lttng.org
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Houssem Daoud | 15 Apr 18:06 2014
Picon

[Patch][Lttng Modules] Statedump event for block devices

Signed-off-by: Houssem Daoud <houssemmh <at> gmail.com>
---
 .../events/lttng-module/lttng-statedump.h          | 15 ++++++
 lttng-statedump-impl.c                             | 60 ++++++++++++++++++++++
 2 files changed, 75 insertions(+)

diff --git a/instrumentation/events/lttng-module/lttng-statedump.h b/instrumentation/events/lttng-module/lttng-statedump.h
index e4c86d6..07afdd0 100644
--- a/instrumentation/events/lttng-module/lttng-statedump.h
+++ b/instrumentation/events/lttng-module/lttng-statedump.h
 <at>  <at>  -141,6 +141,21  <at>  <at>  TRACE_EVENT(lttng_statedump_network_interface,
 	TP_printk("")
 )

+TRACE_EVENT(lttng_statedump_block_device,
+	TP_PROTO(struct lttng_session *session,
+		int dev, const char *diskname),
+	TP_ARGS(session, dev, diskname),
+	TP_STRUCT__entry(
+		__field(int, dev)
+		__string(diskname, diskname)
+	),
+	TP_fast_assign(
+		tp_assign(dev, dev)
+		tp_strcpy(diskname, diskname)
+	),
+	TP_printk("")
+)
+
 /* Called with desc->lock held */
 TRACE_EVENT(lttng_statedump_interrupt,
 	TP_PROTO(struct lttng_session *session,
diff --git a/lttng-statedump-impl.c b/lttng-statedump-impl.c
index 40eab8e..fd0063e 100644
--- a/lttng-statedump-impl.c
+++ b/lttng-statedump-impl.c
 <at>  <at>  -26,6 +26,10  <at>  <at> 
  *	                                Various updates
  */

+#include <linux/ctype.h>
+#include <linux/string.h>
+#include <linux/genhd.h>
+#include <linux/device.h>
 #include <linux/init.h>
 #include <linux/module.h>
 #include <linux/netlink.h>
 <at>  <at>  -54,6 +58,7  <at>  <at> 
 #include "wrapper/nsproxy.h"
 #include "wrapper/irq.h"
 #include "wrapper/tracepoint.h"
+#include "wrapper/kallsyms.h"

 #ifdef CONFIG_LTTNG_HAS_LIST_IRQ
 #include <linux/irq.h>
 <at>  <at>  -108,7 +113,61  <at>  <at>  enum lttng_process_status {
 	LTTNG_DEAD = 7,
 };

+
+char *disk_name(struct gendisk *hd, int partno, char *buf)
+{
+	if (!partno)
+		snprintf(buf, BDEVNAME_SIZE, "%s", hd->disk_name);
+	else if (isdigit(hd->disk_name[strlen(hd->disk_name) - 1]))
+		snprintf(buf, BDEVNAME_SIZE, "%sp%d", hd->disk_name, partno);
+	else
+		snprintf(buf, BDEVNAME_SIZE, "%s%d", hd->disk_name, partno);
+
+	return buf;
+}
+
+static
+int lttng_enumerate_block_devices(struct lttng_session *session) {
+	struct class *ptr_block_class;
+	struct device_type *ptr_disk_type;
+	struct class_dev_iter iter;
+	struct device *dev;
+	struct gendisk *disk;
+	struct disk_part_iter piter;
+	struct hd_struct *part;
+	char name_buf[BDEVNAME_SIZE];
+	int device_devt;
+
+	ptr_block_class = (struct class *) kallsyms_lookup_dataptr("block_class");
+	if (!ptr_block_class){
+		printk( KERN_WARNING "Lttng: block_class symbol lookup failed.\n");
+		return 0;
+	}
+
+	ptr_disk_type = (struct device_type*) kallsyms_lookup_dataptr("disk_type");
+	if (!ptr_disk_type){
+		printk( KERN_WARNING "Lttng: disk_type symbol lookup failed.\n");
+		return 0;
+	}
+
+	class_dev_iter_init(&iter, ptr_block_class, NULL, ptr_disk_type);
+	while ((dev = class_dev_iter_next(&iter))) {
+		disk = dev_to_disk(dev);
+		disk_part_iter_init(&piter, disk, DISK_PITER_INCL_PART0);
+		while ((part = disk_part_iter_next(&piter))) {
+			disk_name(disk, part->partno, name_buf);
+			device_devt = (int) part_devt(part);
+			trace_lttng_statedump_block_device(session, device_devt, name_buf);
+		}
+		disk_part_iter_exit(&piter);
+	}
+	class_dev_iter_exit(&iter);
+
+	return 0;
+}
+
 #ifdef CONFIG_INET
+
 static
 void lttng_enumerate_device(struct lttng_session *session,
 		struct net_device *dev)
 <at>  <at>  -390,6 +449,7  <at>  <at>  int do_lttng_statedump(struct lttng_session *session)
 	/* FIXME lttng_enumerate_vm_maps(session); */
 	lttng_list_interrupts(session);
 	lttng_enumerate_network_ip_interface(session);
+	lttng_enumerate_block_devices(session);

 	/* TODO lttng_dump_idt_table(session); */
 	/* TODO lttng_dump_softirq_vec(session); */
--

-- 
1.8.3.2
Picon

Need help on LTTNG

Hello,

 

I am trying to use LTTNG on centos (2.6.32). I have applied the given patch and rebuilt a kernel.

Still I am unable to build the lltng-modules.

 

[root <at> million lttng-modules-2.4.0]# uname -r

2.6.32-431.5.1.el6.hpsp.centos.LTTNG.18852.x86_64

 

Below is the compiler error I am getting,

 

[root <at> million lttng-modules-2.4.0]# make

make -C /lib/modules/2.6.32-431.5.1.el6.hpsp.centos.LTTNG.18852.x86_64/build M=/root/LTTNG/lttng-modules-2.4.0 modules

make[1]: Entering directory `/usr/src/kernels/2.6.32-431.5.1.el6.hpsp.centos.LTTNG.18852.x86_64'

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-client-discard.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-client-overwrite.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-metadata-client.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-client-mmap-discard.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-client-mmap-overwrite.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-ring-buffer-metadata-mmap-client.o

  CC [M]  /root/LTTNG/lttng-modules-2.4.0/lttng-statedump-impl.o

In file included from /root/LTTNG/lttng-modules-2.4.0/lttng-statedump-impl.c:55:

/root/LTTNG/lttng-modules-2.4.0/wrapper/tracepoint.h: In function âwrapper_lttng_fixup_sigâ:

/root/LTTNG/lttng-modules-2.4.0/wrapper/tracepoint.h:76: error: âstruct moduleâ has no member named âsig_okâ

make[2]: *** [/root/LTTNG/lttng-modules-2.4.0/lttng-statedump-impl.o] Error 1

make[1]: *** [_module_/root/LTTNG/lttng-modules-2.4.0] Error 2

make[1]: Leaving directory `/usr/src/kernels/2.6.32-431.5.1.el6.hpsp.centos.LTTNG.18852.x86_64'

make: *** [default] Error 2

[root <at> million lttng-modules-2.4.0]#

 

Patches provided In lttng-modules/linux-patches/

backport-kallsym-sym-2.6.32.patch               ß got easily applied with patch command

backport-splice-sym-2.6.32-34.patch             ß got easily applied with patch command

backport-tracepoint-data-2.6.32-33.patch     ß  Conflicts were found, and I manually edited tracepoint.h file.

 

Kernel was built by disabling “CONFIG_MODULE_SIG”.  

 

Could you please kindly guide me on this issue. Appreciate your help very much.

Please do let me know, if I need to provide any more info on this.

 

 

Thanks and regards,

Shilpa Kumari.P.V

 

_______________________________________________
lttng-dev mailing list
lttng-dev <at> lists.lttng.org
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

Gmane