mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2026-02-12 16:10:54 +00:00
Fix small bug in add_timeout() More descriptive tree labels update
Sat Mar 12 11:05:19 2005 Soeren Sandmann <sandmann@redhat.com> * sysprof-module.c: Fix small bug in add_timeout() * sysprof.c (build_gui): More descriptive tree labels * TODO: update
This commit is contained in:
committed by
Søren Sandmann Pedersen
parent
e0a2d061c6
commit
64a1ac6355
@ -1,3 +1,9 @@
|
|||||||
|
Sat Mar 12 11:05:19 2005 Soeren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
|
* sysprof-module.c: Fix small bug in add_timeout()
|
||||||
|
* sysprof.c (build_gui): More descriptive tree labels
|
||||||
|
* TODO: update
|
||||||
|
|
||||||
Thu Mar 10 16:37:52 2005 Søren Sandmann <sandmann@redhat.com>
|
Thu Mar 10 16:37:52 2005 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
* sysprof.c (build_gui): s/Cummulative/Cumulative/. Pointed out by
|
* sysprof.c (build_gui): s/Cummulative/Cumulative/. Pointed out by
|
||||||
|
|||||||
3
TODO
3
TODO
@ -1,6 +1,5 @@
|
|||||||
- crashes when you ctrl-click the selected item in the top left pane
|
- crashes when you ctrl-click the selected item in the top left pane
|
||||||
<ian__> ssp: looks like it doesn't handle the none-selected case
|
<ian__> ssp: looks like it doesn't handle the none-selected case
|
||||||
<ian__> Better labels would be useful
|
|
||||||
|
|
||||||
- consider caching [filename => bin_file]
|
- consider caching [filename => bin_file]
|
||||||
- Have kernel modulereport the file the symbol was found in
|
- Have kernel modulereport the file the symbol was found in
|
||||||
@ -8,7 +7,7 @@
|
|||||||
- grep FIXME
|
- grep FIXME
|
||||||
- hide internal stuff in ProfileDescendant
|
- hide internal stuff in ProfileDescendant
|
||||||
- add an 'everything' object. It _is_ really needed for a lot of things
|
- add an 'everything' object. It _is_ really needed for a lot of things
|
||||||
|
- in timer, put process to sleep. Should get us more accurate data
|
||||||
- loading and saving
|
- loading and saving
|
||||||
|
|
||||||
- make profile.c more agnostic to processes and functions etc. Ideally
|
- make profile.c more agnostic to processes and functions etc. Ideally
|
||||||
|
|||||||
1
sfile.c
1
sfile.c
@ -18,6 +18,7 @@ struct SFormat
|
|||||||
|
|
||||||
enum
|
enum
|
||||||
{
|
{
|
||||||
|
TYPE_UNDEFINED = 0,
|
||||||
TYPE_POINTER,
|
TYPE_POINTER,
|
||||||
TYPE_STRING,
|
TYPE_STRING,
|
||||||
TYPE_INTEGER,
|
TYPE_INTEGER,
|
||||||
|
|||||||
7
sfile.h
7
sfile.h
@ -19,6 +19,13 @@ typedef guint SType;
|
|||||||
* serializer_write_int ();
|
* serializer_write_int ();
|
||||||
* serializer_end_write (..., GError **err);
|
* serializer_end_write (..., GError **err);
|
||||||
*
|
*
|
||||||
|
*
|
||||||
|
* For formats consider:
|
||||||
|
*
|
||||||
|
* Format *format_new (void);
|
||||||
|
* void format_new_record (Format *f, Record *r);
|
||||||
|
*
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* - Describing Types - */
|
/* - Describing Types - */
|
||||||
|
|||||||
@ -42,7 +42,6 @@ static struct timer_list timer;
|
|||||||
static void
|
static void
|
||||||
init_timeout (void)
|
init_timeout (void)
|
||||||
{
|
{
|
||||||
timer.function = on_timer;
|
|
||||||
init_timer(&timer);
|
init_timer(&timer);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -56,6 +55,7 @@ static void
|
|||||||
add_timeout(unsigned int interval,
|
add_timeout(unsigned int interval,
|
||||||
TimeoutFunc f)
|
TimeoutFunc f)
|
||||||
{
|
{
|
||||||
|
timer.function = f;
|
||||||
mod_timer(&timer, jiffies + INTERVAL);
|
mod_timer(&timer, jiffies + INTERVAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -79,7 +79,7 @@ init_userspace_reader (userspace_reader *reader,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* This is mostly cutted and pasted from ptrace.c
|
/* This is mostly cutted and pasted from ptrace.c
|
||||||
* I removed some locking and other stuff though. I hope it
|
* I removed some locking and stuff though. I hope it
|
||||||
* wasn't important.
|
* wasn't important.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -303,22 +303,14 @@ static void
|
|||||||
on_timer(unsigned long dong)
|
on_timer(unsigned long dong)
|
||||||
{
|
{
|
||||||
#if 0
|
#if 0
|
||||||
struct task_struct *p;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static const int cpu_profiler = 1; /* set to 0 to profile disk */
|
static const int cpu_profiler = 1; /* set to 0 to profile disk */
|
||||||
|
|
||||||
if (current && current->pid != 0) {
|
if (p->state == (cpu_profiler? TASK_RUNNING : TASK_UNINTERRUPTIBLE))
|
||||||
#if 0
|
;
|
||||||
|
|
||||||
for_each_process (p) {
|
|
||||||
if (p->state == (cpu_profiler? TASK_RUNNING : TASK_UNINTERRUPTIBLE)) {
|
|
||||||
#endif
|
#endif
|
||||||
queue_generate_stack_trace (current);
|
|
||||||
#if 0
|
if (current && current->pid != 0)
|
||||||
}
|
queue_generate_stack_trace (current);
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
add_timeout (INTERVAL, on_timer);
|
add_timeout (INTERVAL, on_timer);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -869,7 +869,7 @@ build_gui (Application *app)
|
|||||||
|
|
||||||
/* object view */
|
/* object view */
|
||||||
app->object_view = (GtkTreeView *)glade_xml_get_widget (xml, "object_view");
|
app->object_view = (GtkTreeView *)glade_xml_get_widget (xml, "object_view");
|
||||||
col = add_plain_text_column (app->object_view, _("Name"), OBJECT_NAME);
|
col = add_plain_text_column (app->object_view, _("Functions"), OBJECT_NAME);
|
||||||
add_double_format_column (app->object_view, _("Self"), OBJECT_SELF, "%.2f");
|
add_double_format_column (app->object_view, _("Self"), OBJECT_SELF, "%.2f");
|
||||||
add_double_format_column (app->object_view, _("Total"), OBJECT_TOTAL, "%.2f");
|
add_double_format_column (app->object_view, _("Total"), OBJECT_TOTAL, "%.2f");
|
||||||
selection = gtk_tree_view_get_selection (app->object_view);
|
selection = gtk_tree_view_get_selection (app->object_view);
|
||||||
@ -879,7 +879,7 @@ build_gui (Application *app)
|
|||||||
|
|
||||||
/* callers view */
|
/* callers view */
|
||||||
app->callers_view = (GtkTreeView *)glade_xml_get_widget (xml, "callers_view");
|
app->callers_view = (GtkTreeView *)glade_xml_get_widget (xml, "callers_view");
|
||||||
col = add_plain_text_column (app->callers_view, _("Name"), CALLERS_NAME);
|
col = add_plain_text_column (app->callers_view, _("Callers"), CALLERS_NAME);
|
||||||
add_double_format_column (app->callers_view, _("Self"), CALLERS_SELF, "%.2f");
|
add_double_format_column (app->callers_view, _("Self"), CALLERS_SELF, "%.2f");
|
||||||
add_double_format_column (app->callers_view, _("Total"), CALLERS_TOTAL, "%.2f");
|
add_double_format_column (app->callers_view, _("Total"), CALLERS_TOTAL, "%.2f");
|
||||||
g_signal_connect (app->callers_view, "row-activated",
|
g_signal_connect (app->callers_view, "row-activated",
|
||||||
@ -889,7 +889,7 @@ build_gui (Application *app)
|
|||||||
|
|
||||||
/* descendants view */
|
/* descendants view */
|
||||||
app->descendants_view = (GtkTreeView *)glade_xml_get_widget (xml, "descendants_view");
|
app->descendants_view = (GtkTreeView *)glade_xml_get_widget (xml, "descendants_view");
|
||||||
col = add_plain_text_column (app->descendants_view, _("Name"), DESCENDANTS_NAME);
|
col = add_plain_text_column (app->descendants_view, _("Descendants"), DESCENDANTS_NAME);
|
||||||
add_double_format_column (app->descendants_view, _("Self"), DESCENDANTS_SELF, "%.2f");
|
add_double_format_column (app->descendants_view, _("Self"), DESCENDANTS_SELF, "%.2f");
|
||||||
add_double_format_column (app->descendants_view, _("Cumulative"), DESCENDANTS_NON_RECURSE, "%.2f");
|
add_double_format_column (app->descendants_view, _("Cumulative"), DESCENDANTS_NON_RECURSE, "%.2f");
|
||||||
g_signal_connect (app->descendants_view, "row-activated",
|
g_signal_connect (app->descendants_view, "row-activated",
|
||||||
|
|||||||
Reference in New Issue
Block a user