Definition at line 13 of file lsprofcalltree.py.
◆ __init__()
def python.ext.lsprofcalltree.KCacheGrind.__init__ |
( |
|
self, |
|
|
|
profiler |
|
) |
| |
◆ _entry()
def python.ext.lsprofcalltree.KCacheGrind._entry |
( |
|
self, |
|
|
|
entry |
|
) |
| |
|
private |
Definition at line 32 of file lsprofcalltree.py.
32 def _entry(self, entry):
33 out_file = self.out_file
35 inlinetime =
int(entry.inlinetime * 1000)
37 if isinstance(code, str):
38 print_(
'fi=~', file=out_file)
40 print_(
'fi=%s' % (code.co_filename,), file=out_file)
41 print_(
'fn=%s' % (
label(code),), file=out_file)
42 if isinstance(code, str):
43 print_(
'0 ', inlinetime, file=out_file)
45 print_(
'%d %d' % (code.co_firstlineno, inlinetime), file=out_file)
51 if isinstance(code, str):
54 lineno = code.co_firstlineno
55 for subentry
in calls:
56 self._subentry(lineno, subentry)
◆ _print_summary()
def python.ext.lsprofcalltree.KCacheGrind._print_summary |
( |
|
self | ) |
|
|
private |
Definition at line 25 of file lsprofcalltree.py.
25 def _print_summary(self):
27 for entry
in self.data:
28 totaltime =
int(entry.totaltime * 1000)
29 max_cost =
max(max_cost, totaltime)
30 print_(
'summary: %d' % (max_cost,), file=self.out_file)
◆ _subentry()
def python.ext.lsprofcalltree.KCacheGrind._subentry |
( |
|
self, |
|
|
|
lineno, |
|
|
|
subentry |
|
) |
| |
|
private |
Definition at line 59 of file lsprofcalltree.py.
59 def _subentry(self, lineno, subentry):
60 out_file = self.out_file
62 totaltime =
int(subentry.totaltime * 1000)
64 print_(
'cfn=%s' % (
label(code),), file=out_file)
65 if isinstance(code, str):
66 print_(
'cfi=~', file=out_file)
67 print_(
'calls=%d 0' % (subentry.callcount,), file=out_file)
69 print_(
'cfi=%s' % (code.co_filename,), file=out_file)
70 print_(
'calls=%d %d' % (
71 subentry.callcount, code.co_firstlineno), file=out_file)
72 print_(
'%d %d' % (lineno, totaltime), file=out_file)
◆ output()
def python.ext.lsprofcalltree.KCacheGrind.output |
( |
|
self, |
|
|
|
out_file |
|
) |
| |
Definition at line 18 of file lsprofcalltree.py.
18 def output(self, out_file):
19 self.out_file = out_file
20 print_(
'events: Ticks', file=out_file)
22 for entry
in self.data:
◆ data
python.ext.lsprofcalltree.KCacheGrind.data |
◆ out_file
python.ext.lsprofcalltree.KCacheGrind.out_file |
The documentation for this class was generated from the following file: