target/i386: Fix bad patch application to translate.c
[qemu/ar7.git] / scripts / tracetool / backend / ust.py
blob4594db612830dc04a05662719f578b50fdac9569
1 #!/usr/bin/env python
2 # -*- coding: utf-8 -*-
4 """
5 LTTng User Space Tracing backend.
6 """
8 __author__ = "Lluís Vilanova <vilanova@ac.upc.edu>"
9 __copyright__ = "Copyright 2012-2016, Lluís Vilanova <vilanova@ac.upc.edu>"
10 __license__ = "GPL version 2 or (at your option) any later version"
12 __maintainer__ = "Stefan Hajnoczi"
13 __email__ = "stefanha@linux.vnet.ibm.com"
16 from tracetool import out
19 PUBLIC = True
22 def generate_h_begin(events, group):
23 out('#include <lttng/tracepoint.h>',
24 '#include "trace/generated-ust-provider.h"',
25 '')
28 def generate_h(event, group):
29 argnames = ", ".join(event.args.names())
30 if len(event.args) > 0:
31 argnames = ", " + argnames
33 out(' tracepoint(qemu, %(name)s%(tp_args)s);',
34 name=event.name,
35 tp_args=argnames)