Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(52)

Unified Diff: collector.h

Issue 6893111: Enhancements to ktop (Closed) Base URL: ssh://gitrw.chromium.org:9222/ktop.git@master
Patch Set: Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Makefile ('k') | collector.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: collector.h
diff --git a/collector.h b/collector.h
new file mode 100644
index 0000000000000000000000000000000000000000..09ededa95231a0c0fa50d304a3bf4f175a0bcdc6
--- /dev/null
+++ b/collector.h
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
+ * Distributed under the terms of the GNU General Public License v2
+ */
+#ifndef _COLLECTOR_H_
+#define _COLLECTOR_H_
+
+#ifndef _STYLE_H_
+#include <style.h>
+#endif
+
+#ifndef _KTOP_H_
+#include <ktop.h>
+#endif
+
+enum { BUF_SIZE = 1 << 12,
+ SMALL_READ = BUF_SIZE >> 2 };
+
+typedef struct ring_header_s {
+ u64 time_stamp;
+ unint commit;
+ u8 data[];
+} ring_header_s;
+
+typedef struct ring_event_s {
+ u32 type_len : 5,
+ time_delta : 27;
+ u32 array[];
+} ring_event_s;
+
+typedef struct event_s {
+ u16 type;
+ u8 flags;
+ u8 preempt_count;
+ s32 pid;
+ s32 lock_depth;
+} event_s;
+
+typedef struct sys_enter_s {
+ event_s ev;
+ snint id;
+ unint arg[NUM_ARGS];
+} sys_enter_s;
+
+typedef struct sys_exit_s {
+ event_s ev;
+ snint id;
+ snint ret;
+} sys_exit_s;
+
+typedef struct Collector_args_s {
+ int cpu_id;
+} Collector_args_s;
+
+int open_raw(int cpu);
+void *dump_collector(void *args);
+
+#endif
« no previous file with comments | « Makefile ('k') | collector.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698