Move current compile tests to 'api1'
[lttng-ust.git] / tests / compile / api1 / ust-fields / ust-fields.c
1 /*
2 * SPDX-License-Identifier: LGPL-2.1-only
3 *
4 * Copyright (C) 2014 Geneviève Bastien <gbastien@versatic.net>
5 */
6
7 #include <unistd.h>
8
9 #define LTTNG_UST_TRACEPOINT_DEFINE
10 #include "ust_tests_ust_fields.h"
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++) {
26 lttng_ust_tracepoint(ust_tests_ust_fields, tptest, i, i % 6,
27 i % 21);
28 }
29
30 for (i = 0; i < 10; i++) {
31 lttng_ust_tracepoint(ust_tests_ust_fields, tptest_bis, i, i % 6);
32 }
33 fprintf(stderr, " done.\n");
34 return 0;
35 }
This page took 0.029295 seconds and 4 git commands to generate.