-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsplat.py
executable file
·962 lines (795 loc) · 45.9 KB
/
splat.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
#!/usr/bin/python
# Copyright (c) IBM 2017 All Rights Reserved.
# Project name: splat
# This project is licensed under the GPL License 2.0, see LICENSE.
import os
import sys
import argparse
import subprocess
if 'PERF_EXEC_PATH' in os.environ:
sys.path.append(os.environ['PERF_EXEC_PATH'] + \
'/scripts/python/Perf-Trace-Util/lib/Perf/Trace')
def debug_print(s):
if params.debug:
print s
parser = argparse.ArgumentParser(formatter_class=argparse.RawDescriptionHelpFormatter,
description='''
Report per-task, per-process, and system-wide lock statistics
Process a perf format trace file containing some or all of the following event sets:
- sdt_libpthread:mutex_acquired
- sdt_libpthread:mutex_entry
- sdt_libpthread:mutex_release
- sched:sched_switch
- sched:sched_migrate_task
- sched:sched_process_fork, sched:sched_process_exec, sched:sched_process_exit
Report the following statistics
- per-process, perf-task, system-wide:
- per-lock:
- acquired count
- elapsed, minimum, maximum, average wait time
- elapsed, minimum, maximum, average hold time
''',
epilog='''
Establish tracepoints:
$ perf probe --add sdt_libpthread:mutex_entry
$ perf probe --add sdt_libpthread:mutex_acquired
$ perf probe --add sdt_libpthread:mutex_release
Note: there may be multiple tracepoints established at each "perf probe" step above. All tracepoints should be recorded in subsequent steps.
Record using perf (to perf.data file):
$ perf record -e '{sdt_libpthread:mutex_acquired,sdt_libpthread_mutex_entry,sdt_libpthread_mutex_release ...}' command
Note: record all tracepoints established above.
Generate report (from perf.data file):
$ ./splat.py
Or, record and report in a single step:
$ ./splat.py --record all command
''')
parser.add_argument('--debug', action='store_true', help='enable debugging output')
parser.add_argument('--window', type=int, help='maximum event sequence length for correcting out-of-order events', default=40)
parser.add_argument('--record',
metavar='EVENTLIST',
help="record events (instead of generating report). "
"Specify event group(s) as a comma-separated list from "
"{all,pthread,sched}.")
parser.add_argument('file_or_command',
nargs=argparse.REMAINDER,
help="the perf format data file to process (default: \"perf.data\"), or "
"the command string to record (with \"--record\")",
metavar='ARG',
default='perf.data')
parser.add_argument('--api', type=int, help='use newer(2) perf API', default=2)
params = parser.parse_args()
if params.record:
eventlist = ''
comma = ''
groups = params.record.split(',')
#if 'all' in groups or 'sched' in groups:
# eventlist = eventlist + comma + "sched:sched_switch," \
# "sched:sched_process_fork,sched:sched_process_exec," \
# "sched:sched_process_exit"
# comma = ','
#if 'all' in groups or 'pthread' in groups:
# eventlist = eventlist + comma + \
# 'raw_syscalls:sys_enter,raw_syscalls:sys_exit'
# comma = ','
if 'all' not in groups:
print "Only 'all' is currently supported for recording groups."
sys.exit(1)
eventlist = 'sdt_libpthread:*,probe_libpthread:*' # hack, should be refined
eventlist = '{' + eventlist + '}'
command = ['perf', 'record', '--quiet', '--all-cpus', '-g',
'--event', eventlist ] + params.file_or_command
if params.debug:
print command
subprocess.call(command)
params.file_or_command = []
try:
from perf_trace_context import *
except:
debug_print("Relaunching under \"perf\" command...")
if len(params.file_or_command) == 0:
params.file_or_command = [ "perf.data" ]
sys.argv = ['perf', 'script', '-i' ] + params.file_or_command + [ '-s', sys.argv[0] ]
sys.argv.append('--')
sys.argv += ['--window', str(params.window)]
sys.argv += ['--api', str(params.api)]
if params.debug:
sys.argv.append('--debug')
debug_print(sys.argv)
os.execvp("perf", sys.argv)
sys.exit(1)
# perf added an additional parameter to event handlers, perf_sample_dict,
# in Linux 4.14 (commit a641860550f05a4b8889dca61aab73c84b2d5e16), which
# altered the event handler API in a binary-incompatible way.
# Using the new API on a system which does not support it results in an
# exception like:
# TypeError: event__handler() takes exactly 11 arguments (10 given)
# Here, we catch all exceptions, and if it seems to match the above
# exception, we attempt to revert to the older perf event handler API.
def checkAPI(t, val, backtrace):
if t == TypeError and str(val).find('takes exactly'):
# remove any existing "--api" parameters
new_argv = []
arg = 0
while arg < len(sys.argv):
if sys.argv[arg].find("--api=") != -1:
pass
elif sys.argv[arg] == "--api":
arg = arg+1
else:
new_argv.append(sys.argv[arg])
arg = arg+1
new_argv.insert(1,"--api=1")
debug_print(new_argv)
os.execvp(new_argv[0],new_argv)
sys.exit(1)
sys.__excepthook__(t, val, backtrace)
from Core import *
from Util import *
def ns2ms(nsecs):
return nsecs * 0.000001
global start_timestamp, curr_timestamp
start_timestamp = 0
curr_timestamp = 0
events = []
n_events = 0
def process_event(event):
global events,n_events,curr_timestamp
i = n_events
while i > 0 and events[i-1].timestamp > event.timestamp:
i = i-1
events.insert(i,event)
if n_events < params.window:
n_events = n_events+1
else:
event = events[0]
# need to delete from events list now,
# because event.process() could reenter here
del events[0]
if event.timestamp < curr_timestamp:
sys.stderr.write("Error: OUT OF ORDER events detected.\n Try increasing the size of the look-ahead window with --window=<n>\n")
event.process()
class Lock:
def __init__(self):
self.timestamp = 0 # mutex initialization time
self.last_event = 0 # recording last event time
self.attempted = 0
self.failed = 0
self.acquired = 0
self.released = 0
self.held = 0 # delta between acquired and release
self.held_min = sys.maxint
self.held_max = 0
self.wait = 0 # delta between entry and acquired
self.wait_min = sys.maxint
self.wait_max = 0
self.pending = 0
def accumulate(self, lock):
self.acquired += lock.acquired
self.failed += lock.failed
self.released += lock.released
self.attempted += lock.attempted
self.held += lock.held
if lock.held_min < self.held_min:
self.held_min = lock.held_min
if lock.held_max > self.held_max:
self.held_max = lock.held_max
self.wait += lock.wait
if lock.wait_min < self.wait_min:
self.wait_min = lock.wait_min
if lock.wait_max > self.wait_max:
self.wait_max = lock.wait_max
def output_header(self):
print "%12s %12s %12s %12s %12s %12s %12s %12s %12s %12s" % ("acquired", "failed", "waited", "minWait", "maxWait", "avgWait", "held", "minHeld", "maxHeld", "avgHeld")
def output(self):
# compute average wait and hold times
if (self.acquired != 0):
avgWait = float(self.wait)/float(self.acquired)/1000000.0
avgHeld = float(self.held)/float(self.acquired)/1000000.0
else:
avgWait = 0.0
avgHeld = 0.0
wait_min = self.wait_min
if wait_min == sys.maxint:
wait_min = 0
held_min = self.held_min
if held_min == sys.maxint:
held_min = 0
print "%12u %12u %12.3f %12.3f %12.3f %12.3f %12.3f %12.3f %12.3f %12.3f" \
% (self.acquired, self.failed, \
float(self.wait)/1000000.0, float(wait_min)/1000000.0, float(self.wait_max)/float(1000000.0), avgWait, \
float(self.held)/1000000.0, float(held_min)/1000000.0, float(self.held_max)/float(1000000.0), avgHeld )
class CPU:
def __init__(self):
self.sys = 0
self.user = 0
self.idle = 0
self.irq = 0
self.hv = 0
self.busy_unknown = 0
self.runtime = 0
self.sleep = 0
self.wait = 0
self.blocked = 0
self.iowait = 0
self.unaccounted = 0
def accumulate(self, cpu):
self.user += cpu.user
self.sys += cpu.sys
self.irq += cpu.irq
self.hv += cpu.hv
self.idle += cpu.idle
self.busy_unknown += cpu.busy_unknown
self.runtime += cpu.runtime
self.sleep += cpu.sleep
self.wait += cpu.wait
self.blocked += cpu.blocked
self.iowait += cpu.iowait
self.unaccounted += cpu.unaccounted
def output_header(self):
print "%12s %12s %12s %12s %12s %12s | %12s %12s %12s %12s %12s %12s | %5s%%" % \
("user", "sys", "irq", "hv", "busy", "idle", "runtime", "sleep", "wait", "blocked", "iowait", "unaccounted", "util"),
def output(self):
print "%12.6f %12.6f %12.6f %12.6f %12.6f %12.6f | %12.6f %12.6f %12.6f %12.6f %12.6f %12.6f" % \
(ns2ms(self.user), ns2ms(self.sys), ns2ms(self.irq), ns2ms(self.hv), ns2ms(self.busy_unknown), ns2ms(self.idle), \
ns2ms(self.runtime), ns2ms(self.sleep), ns2ms(self.wait), ns2ms(self.blocked), ns2ms(self.blocked), ns2ms(self.unaccounted)),
running = self.user + self.sys + self.irq + self.hv + self.busy_unknown
print "| %5.1f%%" % ((float(running * 100) / float(running + self.idle)) if running > 0 else 0),
locks = {}
class LockStats (object):
def __init__(self):
self.attempted = 0
self.failed = 0
self.acquired = 0
self.released = 0
self.wait = 0 # delta between entry and acquired
self.wait_min = sys.maxint
self.wait_max = 0
self.held = 0 # delta between acquired and release
self.held_min = sys.maxint
self.held_max = 0
def output_header(self):
print "%12s %12s %12s %12s %12s %12s %12s %12s %12s %12s %12s %12s" % ("attempted", "failed", "acquired", "released", "wait", "wait avg", "wait min", "wait max", "held", "held avg", "held min", "held max")
def output(self):
print "%12u %12u %12u %12u %12.6f %12.6f %12.6f %12.6f %12.6f %12.6f %12.6f %12.6f" % \
(self.attempted, self.failed, self.acquired, self.released, \
ns2ms(self.wait), \
ns2ms(float(self.wait)/float(self.acquired)) if self.acquired > 0 else 0, \
ns2ms(self.wait_min) if self.acquired > 0 else 0, \
ns2ms(self.wait_max),
ns2ms(self.held), \
ns2ms(float(self.held)/float(self.released)) if self.released > 0 else 0, \
ns2ms(self.held_min) if self.released > 0 else 0, \
ns2ms(self.held_max))
def accumulate(self, lockstat):
self.attempted += lockstat.attempted
self.failed += lockstat.failed
self.acquired += lockstat.acquired
self.released += lockstat.released
self.wait += lockstat.wait
if self.wait_min > lockstat.wait_min:
self.wait_min = lockstat.wait_min
if self.wait_max < lockstat.wait_max:
self.wait_max = lockstat.wait_max
self.held += lockstat.held
if self.held_min > lockstat.held_min:
self.held_min = lockstat.held_min
if self.held_max < lockstat.held_max:
self.held_max = lockstat.held_max
class Task:
def __init__(self, timestamp, tid):
self.timestamp = timestamp
self.tid = tid
self.cpu = 'unknown'
self.cpus = {}
self.functions = {}
self.trying_lid = 0
def output_header(self):
print " -- [%8s] %-20s %3s" % ("task", "command", "cpu"),
for cpu in self.cpus:
self.cpus[cpu].output_header()
break # need just one to emit the header
print "%6s" % ("moves"),
def output_migrations(self):
print "%6u" % (self.migrations),
tasks = {}
class Function (object):
def __init__(self):
self.lockstats = {}
def addLock(tid, func, lid):
try:
lock = locks[lid]
except:
lock = Lock()
locks[lid] = lock
try:
lockstats = tasks[tid].functions[func].lockstats[lid]
except:
try:
f = tasks[tid].functions[func]
except:
f = Function()
tasks[tid].functions[func] = f
lockstats = LockStats()
tasks[tid].functions[func].lockstats[lid] = lockstats
return lock
class Event (object):
def __init__(self):
self.timestamp = 0
self.cpu = 0
self.lid = 0
self.tid = 0
def process(self):
global start_timestamp
try:
task = tasks[self.tid]
except:
task = Task(start_timestamp, self.tid)
tasks[self.tid] = task
debug_print("Adding new task = %u" % self.tid)
if self.cpu not in task.cpus:
debug_print("\tAdding new CPU %d" % self.cpu)
task.cpus[self.cpu] = CPU()
return task
#class Event_mutex_init ( Event ):
#
# def __init__(self, timestamp, cpu, lid, tid):
# self.timestamp = timestamp
# self.cpu = cpu
# self.lid = lid
# self.tid = tid
#
# def process(self):
# global start_timestamp, curr_timestamp
# curr_timestamp = self.timestamp
# if (start_timestamp == 0):
# start_timestamp = curr_timestamp
#
# debug_print("[%7u] Inside Event_mutex_init::process, lid = 0x%x" % (self.tid, self.lid))
# task = super(Event_mutex_init, self).process()
# addLock(self.tid, self.lid)
# task.locks[self.lid].timestamp = curr_timestamp
class Event_mutex_entry_3 ( Event ):
def __init__(self, timestamp, cpu, lid, tid, func):
self.timestamp = timestamp
self.cpu = cpu
self.lid = lid
self.tid = tid
self.function = func
def process(self):
global start_timestamp, curr_timestamp
curr_timestamp = self.timestamp
if (start_timestamp == 0):
start_timestamp = curr_timestamp
debug_print("[%7u] Inside Event_mutex_entry_3::process, lid = 0x%x" % (self.tid, self.lid))
task = super(Event_mutex_entry_3, self).process()
task.trying_lid = self.lid
task.trying_function = self.function
lock = addLock(self.tid, self.function, self.lid)
lockstats = task.functions[self.function].lockstats[self.lid]
lockstats.attempted += 1
lock.last_event = curr_timestamp
class Event_mutex_fail ( Event ):
def __init__(self, timestamp, cpu, lid, tid, func):
self.timestamp = timestamp
self.cpu = cpu
self.lid = lid
self.tid = tid
self.function = func
def process(self):
global start_timestamp, curr_timestamp
curr_timestamp = self.timestamp
if (start_timestamp == 0):
start_timestamp = curr_timestamp
task = super(Event_mutex_fail, self).process()
self.lid = task.trying_lid
self.function = task.trying_function
debug_print("[%7u] Inside Event_mutex_fail::process, lid = 0x%x" % (self.tid, self.lid))
lock = addLock(self.tid, self.function, self.lid)
lockstats = task.functions[self.function].lockstats[self.lid]
lockstats.failed += 1
lock.last_event = curr_timestamp
class Event_mutex_acquired_7 ( Event ):
def __init__(self, timestamp, cpu, lid, tid, func):
self.timestamp = timestamp
self.cpu = cpu
self.lid = lid
self.tid = tid
self.function = func
def process(self):
global start_timestamp, curr_timestamp
curr_timestamp = self.timestamp
if (start_timestamp == 0):
start_timestamp = curr_timestamp
task = super(Event_mutex_acquired_7, self).process()
if self.lid == 0:
self.lid = task.trying_lid
self.function = task.trying_function
debug_print("[%7u] Inside Event_mutex_acquired_7::process, lid = 0x%x" % (self.tid, self.lid))
lock = addLock(self.tid, self.function, self.lid)
lockstats = task.functions[self.function].lockstats[self.lid]
# wait = delta b/w mutex entry & acquired
waitTime = (curr_timestamp - lock.last_event)
lockstats.wait += waitTime
# update min & max wait time
if (waitTime < lockstats.wait_min):
lockstats.wait_min = waitTime
if (waitTime > lockstats.wait_max):
lockstats.wait_max = waitTime
lockstats.acquired += 1
lock.last_event = curr_timestamp
class Event_mutex_release_7 ( Event ):
def __init__(self, timestamp, cpu, lid, tid, func):
self.timestamp = timestamp
self.cpu = cpu
self.lid = lid
self.tid = tid
self.function = func
def process(self):
global start_timestamp, curr_timestamp
curr_timestamp = self.timestamp
if (start_timestamp == 0):
start_timestamp = curr_timestamp
debug_print("[%7u] Inside Event_mutex_release_7::process, lid = 0x%x" % (self.tid, self.lid))
task = super(Event_mutex_release_7, self).process()
lock = addLock(self.tid, self.function, self.lid)
lockstats = task.functions[self.function].lockstats[self.lid]
# held = delta b/w mutex acquired & released
heldTime = (curr_timestamp - lock.last_event)
lockstats.held += heldTime
# update min & max held time
if (heldTime < lockstats.held_min):
lockstats.held_min = heldTime
if (heldTime > lockstats.held_max):
lockstats.held_max = heldTime
lockstats.released += 1
#def sdt_libpthread__mutex_destroy_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm,
# common_callchain, __probe_ip, arg1, perf_sample_dict):
# # print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# # print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
# debug_print("Destroying mutex, id = 0x%x" % arg1)
#def sdt_libpthread__mutex_destroy_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
# sdt_libpthread__mutex_destroy_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def trace_begin():
debug_print("in trace_begin")
def trace_end():
debug_print("in trace_end")
global events
for event in events:
event.process()
mutexTotals()
def mutexTotals():
lockstats = {}
# print header
# print "%20s" % (''),
for tid in tasks:
print ""
print "Task [%9u]" % (tid)
for func in tasks[tid].functions:
print " Function \"%s\"" % (func)
for lid in tasks[tid].functions[func].lockstats:
print " lock",
tasks[tid].functions[func].lockstats[lid].output_header()
break
# print mutex list
for lid in sorted(tasks[tid].functions[func].lockstats, key = lambda x: (tasks[tid].functions[func].lockstats[x].acquired), reverse=True):
print "%16x" % (lid),
tasks[tid].functions[func].lockstats[lid].output()
if lid not in lockstats:
lockstats[lid] = LockStats()
lockstats[lid].accumulate(tasks[tid].functions[func].lockstats[lid])
print ""
print "Task [%9s]" % ("ALL")
print " lock",
for lid in locks:
locks[lid].output_header()
break
for lid in locks:
locks[lid].attempted = lockstats[lid].attempted
locks[lid].failed = lockstats[lid].failed
locks[lid].wait = lockstats[lid].wait
locks[lid].wait_min = lockstats[lid].wait_min
locks[lid].wait_max = lockstats[lid].wait_max
locks[lid].acquired = lockstats[lid].acquired
locks[lid].held = lockstats[lid].held
locks[lid].held_min = lockstats[lid].held_min
locks[lid].held_max = lockstats[lid].held_max
locks[lid].released = lockstats[lid].released
for lid in sorted(locks, key = lambda x: (locks[x].acquired), reverse=True):
print "%16x" % (lid),
locks[lid].output()
def get_caller(callchain):
try:
caller = callchain[1]['sym']['name']
try:
offset = callchain[1]['ip'] - callchain[1]['sym']['start']
caller = caller + "+0x%x" % offset
except:
pass
except:
try:
caller = callchain[1]['dso']
try:
offset = callchain[1]['ip']
caller = caller + "+0x%x" % offset
except:
pass
except:
caller = 'unknown'
return caller
def sdt_libpthread__pthread_create_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % (__probe_ip)
pass
def sdt_libpthread__pthread_create_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__pthread_create_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__pthread_create_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3, arg4, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u, arg2=%u, arg3=%u, arg4=%u" % (__probe_ip, arg1, arg2, arg3, arg4)
pass
def sdt_libpthread__pthread_create_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3, arg4):
sdt_libpthread__pthread_create_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3, arg4, dummy_dict)
def sdt_libpthread__pthread_join_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % (__probe_ip)
pass
def sdt_libpthread__pthread_join_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__pthread_join_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__pthread_join_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
pass
def sdt_libpthread__pthread_join_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__pthread_join_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__pthread_join_ret_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % (__probe_ip)
pass
def sdt_libpthread__pthread_join_ret_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__pthread_join_ret_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__mutex_acquired_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_acquired_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_acquired_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_acquired_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_acquired_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_acquired_2_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_acquired_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_acquired_3_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_acquired_4_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
print "sdt_libpthread::mutex_acquired_4 not handled"
def sdt_libpthread__mutex_acquired_4_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__mutex_acquired_4_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__mutex_acquired_5_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
print "sdt_libpthread::mutex_acquired_4 not handled"
def sdt_libpthread__mutex_acquired_5_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_5_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_acquired_6_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
print "sdt_libpthread::mutex_acquired_4 not handled"
def sdt_libpthread__mutex_acquired_6_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__mutex_acquired_6_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__mutex_acquired_7_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_acquired_7_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_acquired_7_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
#def sdt_libpthread__mutex_destroy_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# # print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# # print "__probe_ip=%u" % (__probe_ip)
# pass
#def sdt_libpthread__mutex_destroy_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
# sdt_libpthread__mutex_destroy_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__mutex_entry_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_entry_3 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_entry_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_entry_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_entry_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_entry_3 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_entry_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_entry_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_entry_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_entry_3 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_entry_2_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__mutex_entry_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__mutex_entry_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
event = Event_mutex_entry_3 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_entry_3_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_entry_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
#def sdt_libpthread__mutex_init_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# # print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# # print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
# event = Event_mutex_init (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid)
# process_event(event)
#def sdt_libpthread__mutex_init_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
# sdt_libpthread__mutex_init_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
#def sdt_libpthread__mutex_init_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# # print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# # print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
# event = Event_mutex_init (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid)
# process_event(event)
#def sdt_libpthread__mutex_init_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
# sdt_libpthread__mutex_init_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_2_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_2_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_3_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_3_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_4_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_4_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_4_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_5_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_5_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_5_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_6_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_6_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_6_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__mutex_release_7_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u" % (__probe_ip, arg1)
event = Event_mutex_release_7 (nsecs(common_secs,common_nsecs), common_cpu, arg1, common_pid, get_caller(common_callchain))
process_event(event)
def sdt_libpthread__mutex_release_7_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1):
sdt_libpthread__mutex_release_7_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, dummy_dict)
def sdt_libpthread__pthread_start_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % (__probe_ip)
pass
def sdt_libpthread__pthread_start_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
sdt_libpthread__pthread_start_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def sdt_libpthread__pthread_start_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u, arg1=%u, arg2=%u, arg3=%u" % (__probe_ip, arg1, arg2, arg3)
pass
def sdt_libpthread__pthread_start_1_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3):
sdt_libpthread__pthread_start_1_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, arg1, arg2, arg3, dummy_dict)
def probe_libpthread__pthread_mutex_lock_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % \ (__probe_ip)
pass
def probe_libpthread__pthread_mutex_lock_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
probe_libpthread__pthread_mutex_lock_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def probe_libpthread__pthread_mutex_unlock_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# print "__probe_ip=%u" % \ (__probe_ip)
pass
def probe_libpthread__pthread_mutex_unlock_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
probe_libpthread__pthread_mutex_unlock_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
#def probe_libpthread__pthread_mutex_init_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, perf_sample_dict):
# # print_header(event_name, common_cpu, common_secs, common_nsecs, common_pid, common_comm)
# # print "__probe_ip=%u" % (__probe_ip)
# pass
#def probe_libpthread__pthread_mutex_init_old(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip):
# probe_libpthread__pthread_mutex_init_new(event_name, context, common_cpu, common_secs, common_nsecs, common_pid, common_comm, common_callchain, __probe_ip, dummy_dict)
def probe_libpthread__pthread_mutex_trylock(event_name, context, common_cpu,
common_secs, common_nsecs, common_pid, common_comm,
common_callchain, __probe_ip, mutex):
event = Event_mutex_entry_3 (nsecs(common_secs,common_nsecs), common_cpu, mutex, common_pid, get_caller(common_callchain))
process_event(event)
def probe_libpthread__pthread_mutex_trylock_ret(event_name, context, common_cpu,
common_secs, common_nsecs, common_pid, common_comm,
common_callchain, __probe_func, __probe_ret_ip, ret):
if (ret == 0):
event = Event_mutex_acquired_7 (nsecs(common_secs,common_nsecs), common_cpu, 0, common_pid, get_caller(common_callchain))
else:
event = Event_mutex_fail (nsecs(common_secs,common_nsecs), common_cpu, 0, common_pid, get_caller(common_callchain))
process_event(event)
def trace_unhandled(event_name, context, event_fields_dict):
#print "trace_unhandled %s" % (event_name)
# print ' '.join(['%s=%s'%(k,str(v))for k,v in sorted(event_fields_dict.items())])
pass
def print_header(event_name, cpu, secs, nsecs, pid, comm):
#print "%-20s %5u %05u.%09u %8u %-20s " % (event_name, cpu, secs, nsecs, pid, comm),
pass
if params.api == 1:
dummy_dict = {}
dummy_dict['sample'] = {}
dummy_dict['sample']['pid'] = 'unknown'
# sdt_libpthread__mutex_destroy_1 = sdt_libpthread__mutex_destroy_1_old
sdt_libpthread__pthread_create = sdt_libpthread__pthread_create_old
sdt_libpthread__pthread_create_1 = sdt_libpthread__pthread_create_1_old
sdt_libpthread__pthread_join = sdt_libpthread__pthread_join_old
sdt_libpthread__pthread_join_1 = sdt_libpthread__pthread_join_1_old
sdt_libpthread__pthread_join_ret = sdt_libpthread__pthread_join_ret_old
sdt_libpthread__mutex_acquired = sdt_libpthread__mutex_acquired_old
sdt_libpthread__mutex_acquired_1 = sdt_libpthread__mutex_acquired_1_old
sdt_libpthread__mutex_acquired_2 = sdt_libpthread__mutex_acquired_2_old
sdt_libpthread__mutex_acquired_3 = sdt_libpthread__mutex_acquired_3_old
sdt_libpthread__mutex_acquired_4 = sdt_libpthread__mutex_acquired_4_old
sdt_libpthread__mutex_acquired_5 = sdt_libpthread__mutex_acquired_5_old
sdt_libpthread__mutex_acquired_6 = sdt_libpthread__mutex_acquired_6_old
sdt_libpthread__mutex_acquired_7 = sdt_libpthread__mutex_acquired_7_old
# sdt_libpthread__mutex_destroy = sdt_libpthread__mutex_destroy_old
sdt_libpthread__mutex_entry = sdt_libpthread__mutex_entry_old
sdt_libpthread__mutex_entry_1 = sdt_libpthread__mutex_entry_1_old
sdt_libpthread__mutex_entry_2 = sdt_libpthread__mutex_entry_2_old
sdt_libpthread__mutex_entry_3 = sdt_libpthread__mutex_entry_3_old
# sdt_libpthread__mutex_init = sdt_libpthread__mutex_init_old
# sdt_libpthread__mutex_init_1 = sdt_libpthread__mutex_init_1_old
sdt_libpthread__mutex_release = sdt_libpthread__mutex_release_old
sdt_libpthread__mutex_release_1 = sdt_libpthread__mutex_release_1_old
sdt_libpthread__mutex_release_2 = sdt_libpthread__mutex_release_2_old
sdt_libpthread__mutex_release_3 = sdt_libpthread__mutex_release_3_old
sdt_libpthread__mutex_release_4 = sdt_libpthread__mutex_release_4_old
sdt_libpthread__mutex_release_5 = sdt_libpthread__mutex_release_5_old
sdt_libpthread__mutex_release_6 = sdt_libpthread__mutex_release_6_old
sdt_libpthread__mutex_release_7 = sdt_libpthread__mutex_release_7_old
sdt_libpthread__pthread_start = sdt_libpthread__pthread_start_old
sdt_libpthread__pthread_start_1 = sdt_libpthread__pthread_start_1_old
probe_libpthread__pthread_mutex_lock = probe_libpthread__pthread_mutex_lock_old
probe_libpthread__pthread_mutex_unlock = probe_libpthread__pthread_mutex_unlock_old
# probe_libpthread__pthread_mutex_init = probe_libpthread__pthread_mutex_init_old
else:
sys.excepthook = checkAPI
# sdt_libpthread__mutex_destroy_1 = sdt_libpthread__mutex_destroy_1_new
sdt_libpthread__pthread_create = sdt_libpthread__pthread_create_new
sdt_libpthread__pthread_create_1 = sdt_libpthread__pthread_create_1_new
sdt_libpthread__pthread_join = sdt_libpthread__pthread_join_new
sdt_libpthread__pthread_join_1 = sdt_libpthread__pthread_join_1_new
sdt_libpthread__pthread_join_ret = sdt_libpthread__pthread_join_ret_new
sdt_libpthread__mutex_acquired = sdt_libpthread__mutex_acquired_new
sdt_libpthread__mutex_acquired_1 = sdt_libpthread__mutex_acquired_1_new
sdt_libpthread__mutex_acquired_2 = sdt_libpthread__mutex_acquired_2_new
sdt_libpthread__mutex_acquired_3 = sdt_libpthread__mutex_acquired_3_new
sdt_libpthread__mutex_acquired_4 = sdt_libpthread__mutex_acquired_4_new
sdt_libpthread__mutex_acquired_5 = sdt_libpthread__mutex_acquired_5_new
sdt_libpthread__mutex_acquired_6 = sdt_libpthread__mutex_acquired_6_new
sdt_libpthread__mutex_acquired_7 = sdt_libpthread__mutex_acquired_7_new
# sdt_libpthread__mutex_destroy = sdt_libpthread__mutex_destroy_new
sdt_libpthread__mutex_entry = sdt_libpthread__mutex_entry_new
sdt_libpthread__mutex_entry_1 = sdt_libpthread__mutex_entry_1_new
sdt_libpthread__mutex_entry_2 = sdt_libpthread__mutex_entry_2_new
sdt_libpthread__mutex_entry_3 = sdt_libpthread__mutex_entry_3_new
# sdt_libpthread__mutex_init = sdt_libpthread__mutex_init_new
# sdt_libpthread__mutex_init_1 = sdt_libpthread__mutex_init_1_new
sdt_libpthread__mutex_release = sdt_libpthread__mutex_release_new
sdt_libpthread__mutex_release_1 = sdt_libpthread__mutex_release_1_new
sdt_libpthread__mutex_release_2 = sdt_libpthread__mutex_release_2_new
sdt_libpthread__mutex_release_3 = sdt_libpthread__mutex_release_3_new
sdt_libpthread__mutex_release_4 = sdt_libpthread__mutex_release_4_new
sdt_libpthread__mutex_release_5 = sdt_libpthread__mutex_release_5_new
sdt_libpthread__mutex_release_6 = sdt_libpthread__mutex_release_6_new
sdt_libpthread__mutex_release_7 = sdt_libpthread__mutex_release_7_new
sdt_libpthread__pthread_start = sdt_libpthread__pthread_start_new
sdt_libpthread__pthread_start_1 = sdt_libpthread__pthread_start_1_new
probe_libpthread__pthread_mutex_lock = probe_libpthread__pthread_mutex_lock_new
probe_libpthread__pthread_mutex_unlock = probe_libpthread__pthread_mutex_unlock_new
# probe_libpthread__pthread_mutex_init = probe_libpthread__pthread_mutex_init_new