[...]
If the trace events from both LTTng and perf represent the same thingOkay. So I found this file for linuxtools now let me try tracecompass.
(and I assume they should, since they come from the same tracepoints,
right?), then we could just add a wrapper on the viewer side to
decide which event/field names to use, depending on the trace type.
Right now, we only define LTTng event and field names:
http://git.eclipse.org/c/tracecompass/org.eclipse.tracecompass.git/tree/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/LttngStrings.java
The basic renaming should do the job. Then I have to figure out how to
compile this thingyâ
There is this one thing where you go for "tid" while perf says "pid". I
guess I could figure that out once I have the rename done.
We don't have lttng_statedump_process_state, this look lttng specific. I
would have to look if there is a replacement event in perf.
I have no idea what we could do about the "unknown" events, say someone
enbales skb tracing. But this is probably something for once we are
done with the basic integration.
But if you could for example tell me the perf equivalents of all theOooh, that would be awesome. So I installed maven but didn't get much
strings in that file, I could hack together such wrapper. With that,
in theory, perf traces should behave exactly the same as LTTng traces
in the viewer!
further. Let me gather this for you.
So first the renaming:
diff --git a/LttngStrings.java b/LttngStrings.java
--- a/LttngStrings.java
+++ b/LttngStrings.java
@@ -27,17 +27,17 @@ public interface LttngStrings {
/* Event names */
static final String EXIT_SYSCALL = "exit_syscall";
- static final String IRQ_HANDLER_ENTRY = "irq_handler_entry";
- static final String IRQ_HANDLER_EXIT = "irq_handler_exit";
- static final String SOFTIRQ_ENTRY = "softirq_entry";
- static final String SOFTIRQ_EXIT = "softirq_exit";
- static final String SOFTIRQ_RAISE = "softirq_raise";
- static final String SCHED_SWITCH = "sched_switch";
- static final String SCHED_WAKEUP = "sched_wakeup";
- static final String SCHED_WAKEUP_NEW = "sched_wakeup_new";
- static final String SCHED_PROCESS_FORK = "sched_process_fork";
- static final String SCHED_PROCESS_EXIT = "sched_process_exit";
- static final String SCHED_PROCESS_FREE = "sched_process_free";
+ static final String IRQ_HANDLER_ENTRY = "irq:irq_handler_entry";
+ static final String IRQ_HANDLER_EXIT = "irq:irq_handler_exit";
+ static final String SOFTIRQ_ENTRY = "irq:softirq_entry";
+ static final String SOFTIRQ_EXIT = "irq:softirq_exit";
+ static final String SOFTIRQ_RAISE = "irq:softirq_raise";
+ static final String SCHED_SWITCH = "sched:sched_switch";
+ static final String SCHED_WAKEUP = "sched:sched_wakeup";
+ static final String SCHED_WAKEUP_NEW = "sched:sched_wakeup_new";
+ static final String SCHED_PROCESS_FORK = "sched:sched_process_fork";
+ static final String SCHED_PROCESS_EXIT = "sched:sched_process_exit";
+ static final String SCHED_PROCESS_FREE = "sched:sched_process_free";
static final String STATEDUMP_PROCESS_STATE = "lttng_statedump_process_state";
/* System call names */
I have no idea how exit_syscall is different from irq_handler_exit and I
think we have to skip for now on STATEDUMP_PROCESS_STATE.
For the syscalls:
- static final String SYSCALL_PREFIX = "sys_";
It is bassicaly:
syscalls:sys_enter_
syscalls:sys_exit_
depending what you are looking for.
- static final String COMPAT_SYSCALL_PREFIX = "compat_sys_";
I haven't found this. Could it be that we don't record the compat_sys
at all?
- static final String SYS_CLONE = "sys_clone";
here we have
syscalls:sys_enter_clone
syscalls:sys_exit_clone
I guess the enter is what you are looking for.
For the fields, this is one event with alle the members we have. Please
note that lttng saves the members with the _ prefix and I haven't seen
that prefix in that .java file.