1V4L2-TRACER(1)                     1.25.0""                     V4L2-TRACER(1)
2
3
4

NAME

6       v4l2-tracer - An application to trace and replay stateless video decod‐
7       ing.
8

SYNOPSIS

10       v4l2-tracer [options] trace <tracee>
11       v4l2-tracer [options] retrace  <trace_file>.json
12       v4l2-tracer clean  <file>.json
13
14

DESCRIPTION

16       The v4l2-tracer utility traces, records and replays userspace  applica‐
17       tions  that implement the v4l2 memory-to-memory stateless video decoder
18       interface.
19
20   Trace
21       Trace system calls and video frame data passed by userspace application
22       <tracee>  to kernel driver.  All stateless codec controls in user-space
23       API can be traced. Outputs a JSON-formatted trace file.
24
25   Retrace
26       Read the JSON-formatted <trace_file>.json. Replay the same system calls
27       and  pass  the same video frame data to kernel driver.  Outputs a JSON-
28       formatted retrace file.
29
30
31   Clean
32       Remove lines with irrelevant differences  (e.g.  file  descriptors  and
33       memory addresses) from JSON files.  Outputs a clean copy, not necessar‐
34       ily still in JSON-format.
35
36

OPTIONS

38   Common Options
39       -c, --compact
40              Write minimal whitespace in JSON file.
41
42       -g, --debug
43              Turn on verbose reporting plus additional debug info.
44
45       -h, --help
46              Display this message.
47
48       -r, --raw
49              Write decoded video frame data to JSON file.
50
51       -v, --verbose
52              Turn on verbose reporting.
53
54       -y, --yuv
55              Write decoded video frame data to yuv file.
56
57
58   Retrace Options
59       -d, --device <dev>
60              Use a different video device than specified in the trace file.
61              <dev>  must  be   a   digit   corresponding   to   an   existing
62              /dev/video<dev>
63
64       -m, --media <dev>
65              Use a different media device than specified in the trace file.
66              <dev>  must  be  a  digit  corresponding to an existing /dev/me‐
67              dia<dev>
68
69

EXIT STATUS

71       On success, it returns 0. Otherwise, it will return 1 or an error code.
72
73

EXAMPLE

75       Trace an application decoding VP8 video:
76              v4l2-tracer trace gst-launch-1.0 -- filesrc location=test-25fps.vp8 ! parsebin ! v4l2slvp8dec ! videocodectestsink
77
78       A trace file is generated:
79              71827_trace.json
80
81       Retrace the trace file:
82              v4l2-tracer retrace 71827_trace.json
83
84       Specify device nodes if retracing on a different driver:
85              v4l2-tracer -d0 -m0 retrace 71827_trace.json
86
87       A retrace file is generated:
88              71827_trace_retrace.json
89
90       Remove file descriptors and addresses (optional):
91              v4l2-tracer clean 71827_trace.json
92              v4l2-tracer clean 71827_trace_retrace.json
93
94       Clean files are generated for comparison:
95              clean_71827_trace.json
96              clean_71827_trace_retrace.json
97
98

BUGS

100       Bug reports or questions about this  utility  should  be  sent  to  the
101       linux-media@vger.kernel.org mailinglist.
102
103
104
105v4l-utils                        November 2022                  V4L2-TRACER(1)
Impressum