forked from cirosantilli/linux-kernel-module-cheat
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathqemu-trace2txt
More file actions
executable file
·29 lines (24 loc) · 790 Bytes
/
qemu-trace2txt
File metadata and controls
executable file
·29 lines (24 loc) · 790 Bytes
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
#!/usr/bin/env python3
import os
import common
from shell_helpers import LF
class Main(common.LkmcCliFunction):
def __init__(self):
super().__init__(
description='''\
Convert a QEMU `-trace exec_tb` to text form.
'''
)
def timed_main(self):
return self.sh.run_cmd(
[
os.path.join(self.env['qemu_source_dir'], 'scripts/simpletrace.py'), LF,
os.path.join(self.env['qemu_build_dir'], 'trace-events-all'), LF,
os.path.join(self.env['qemu_trace_file']), LF,
],
cmd_file=os.path.join(self.env['run_dir'], 'qemu-trace2txt'),
out_file=self.env['qemu_trace_txt_file'],
show_stdout=False,
)
if __name__ == '__main__':
Main().cli()