Commit | Line | Data |
---|---|---|
c785c634 | 1 | /* |
c0c0989a | 2 | * SPDX-License-Identifier: LGPL-2.1-only |
c785c634 | 3 | * |
c0c0989a | 4 | * Copyright (C) 2014 Geneviève Bastien <gbastien@versatic.net> |
c785c634 MD |
5 | */ |
6 | ||
7 | #include <unistd.h> | |
8 | ||
88c7c4ea | 9 | #define LTTNG_UST_TRACEPOINT_DEFINE |
bebb067e | 10 | #include "ust_tests_ust_fields.h" |
c785c634 MD |
11 | |
12 | int main(int argc, char **argv) | |
13 | { | |
14 | int i; | |
15 | int delay = 0; | |
16 | ||
17 | if (argc == 2) | |
18 | delay = atoi(argv[1]); | |
19 | ||
20 | fprintf(stderr, "Hello, World!\n"); | |
21 | ||
22 | sleep(delay); | |
23 | ||
24 | fprintf(stderr, "Tracing... "); | |
25 | for (i = 0; i < 100; i++) { | |
bebb067e | 26 | lttng_ust_tracepoint(ust_tests_ust_fields, tptest, i, i % 6, |
c785c634 MD |
27 | i % 21); |
28 | } | |
29 | ||
30 | for (i = 0; i < 10; i++) { | |
bebb067e | 31 | lttng_ust_tracepoint(ust_tests_ust_fields, tptest_bis, i, i % 6); |
c785c634 MD |
32 | } |
33 | fprintf(stderr, " done.\n"); | |
34 | return 0; | |
35 | } |