#include <string.h>
#include <ltt/ltt-private.h>
#include <string.h>
#include <ltt/ltt-private.h>
-guint64 nr_states = 0;
-
/* Comment :
* Mathieu Desnoyers
* usertrace is there only to be able to update the current CPU of the
/* Comment :
* Mathieu Desnoyers
* usertrace is there only to be able to update the current CPU of the
LttvTraceState *ts = LTTV_TRACE_STATE(tfs->parent.t_context);
LttvProcessState key;
LttvTraceState *ts = LTTV_TRACE_STATE(tfs->parent.t_context);
LttvProcessState key;
/* Wait for both schedule with exit dead and process free to happen.
* They can happen in any order. */
if (++(process->free_events) < 2)
/* Wait for both schedule with exit dead and process free to happen.
* They can happen in any order. */
if (++(process->free_events) < 2)
struct marker_field *f = lttv_trace_get_hook_field(th, 0);
LttvExecutionSubmode submode;
struct marker_field *f = lttv_trace_get_hook_field(th, 0);
LttvExecutionSubmode submode;
guint syscall = ltt_event_get_unsigned(e, f);
expand_syscall_table(ts, syscall);
submode = ((LttvTraceState *)(s->parent.t_context))->syscall_names[syscall];
guint syscall = ltt_event_get_unsigned(e, f);
expand_syscall_table(ts, syscall);
submode = ((LttvTraceState *)(s->parent.t_context))->syscall_names[syscall];
LttvExecutionSubmode submode;
LttvExecutionSubmode submode;
guint64 trap = ltt_event_get_long_unsigned(e, f);
expand_trap_table(ts, trap);
guint64 trap = ltt_event_get_long_unsigned(e, f);
expand_trap_table(ts, trap);
LttvTraceHook *th = (LttvTraceHook *)hook_data;
struct marker_field *f = lttv_trace_get_hook_field(th, 0);
LttvTraceHook *th = (LttvTraceHook *)hook_data;
struct marker_field *f = lttv_trace_get_hook_field(th, 0);
LttvExecutionSubmode submode;
guint64 irq = ltt_event_get_long_unsigned(e, f);
LttvExecutionSubmode submode;
guint64 irq = ltt_event_get_long_unsigned(e, f);
expand_soft_irq_table(ts, softirq);
submode = ((LttvTraceState *)(s->parent.t_context))->soft_irq_names[softirq];
expand_soft_irq_table(ts, softirq);
submode = ((LttvTraceState *)(s->parent.t_context))->soft_irq_names[softirq];
/* Do something with the info about being in user or system mode when int? */
push_state(s, LTTV_STATE_SOFT_IRQ, submode);
/* Do something with the info about being in user or system mode when int? */
push_state(s, LTTV_STATE_SOFT_IRQ, submode);
lttv_trace_get_hook_field(th, 2));
guint16 devcode = MKDEV(major,minor);
lttv_trace_get_hook_field(th, 2));
guint16 devcode = MKDEV(major,minor);
/* have we seen this block device before? */
gpointer bdev = get_hashed_bdevstate(ts, devcode);
/* have we seen this block device before? */
gpointer bdev = get_hashed_bdevstate(ts, devcode);
pid_in = ltt_event_get_unsigned(e, lttv_trace_get_hook_field(th, 1));
state_out = ltt_event_get_long_int(e, lttv_trace_get_hook_field(th, 2));
pid_in = ltt_event_get_unsigned(e, lttv_trace_get_hook_field(th, 1));
state_out = ltt_event_get_long_int(e, lttv_trace_get_hook_field(th, 2));
if(likely(process != NULL)) {
/* We could not know but it was not the idle process executing.
if(likely(process != NULL)) {
/* We could not know but it was not the idle process executing.
LttvProcessState *child_process;
struct marker_field *f;
LttvProcessState *child_process;
struct marker_field *f;
/* Parent PID */
parent_pid = ltt_event_get_unsigned(e, lttv_trace_get_hook_field(th, 0));
/* Parent PID */
parent_pid = ltt_event_get_unsigned(e, lttv_trace_get_hook_field(th, 0));
guint cpu = s->cpu;
LttvProcessState *process = ts->running_process[cpu];
guint cpu = s->cpu;
LttvProcessState *process = ts->running_process[cpu];
#if 0//how to use a sequence that must be transformed in a string
/* PID of the process to release */
guint64 name_len = ltt_event_field_element_number(e,
#if 0//how to use a sequence that must be transformed in a string
/* PID of the process to release */
guint64 name_len = ltt_event_field_element_number(e,
#define LTTV_STATE_SAVE_INTERVAL 50000
#define LTTV_STATE_SAVE_INTERVAL 50000
-extern guint64 nr_states;
/* Facilities Quarks */
extern GQuark
/* Facilities Quarks */
extern GQuark
g_info("TextDump traceset footer");
fprintf(a_file,"End trace set\n\n");
g_info("TextDump traceset footer");
fprintf(a_file,"End trace set\n\n");
- fprintf(a_file,"nr states created (total) : %llu\n\n", nr_states);
if(LTTV_IS_TRACESET_STATS(tc)) {
lttv_stats_sum_traceset((LttvTracesetStats *)tc, ltt_time_infinite);
if(LTTV_IS_TRACESET_STATS(tc)) {
lttv_stats_sum_traceset((LttvTracesetStats *)tc, ltt_time_infinite);