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

Unified Diff: tools/traceline/traceline/scripts/alloc.py

Issue 20494: Import Traceline, a Windows performance trace event logger. (Closed)
Patch Set: Feedback. Created 11 years, 10 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 | « tools/traceline/traceline/rdtsc.h ('k') | tools/traceline/traceline/scripts/crit_sec.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/traceline/traceline/scripts/alloc.py
diff --git a/tools/traceline/traceline/scripts/alloc.py b/tools/traceline/traceline/scripts/alloc.py
new file mode 100755
index 0000000000000000000000000000000000000000..d89447a1f6c5a56565a188c8ac7989d6a9ee7ed5
--- /dev/null
+++ b/tools/traceline/traceline/scripts/alloc.py
@@ -0,0 +1,21 @@
+# Copyright (c) 2009 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import sys
+
+execfile(os.path.join(
+ os.path.dirname(os.path.join(os.path.curdir, __file__)),
+ 'syscalls.py'))
+
+def parseEvents(z):
+ calls = { }
+ for e in z:
+ if e['eventtype'] == 'EVENT_TYPE_SYSCALL' and e['syscall'] == 17:
+ delta = e['done'] - e['ms']
+ tid = e['thread']
+ ms = e['ms']
+ print '%f - %f - %x' % (
+ delta, ms, tid)
+
+execfile(sys.argv[1])
« no previous file with comments | « tools/traceline/traceline/rdtsc.h ('k') | tools/traceline/traceline/scripts/crit_sec.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698