Use %ull here.
[llvm/stm8.git] / runtime / libprofile / LineProfiling.c
blob786dc6e8e12e136eb27d90192ceeb628d2815aef
1 /*===- LineProfiling.c - Support library for line profiling ---------------===*\
2 |*
3 |* The LLVM Compiler Infrastructure
4 |*
5 |* This file is distributed under the University of Illinois Open Source
6 |* License. See LICENSE.TXT for details.
7 |*
8 |*===----------------------------------------------------------------------===*|
9 |*
10 |* This file implements the call back routines for the line profiling
11 |* instrumentation pass. Link against this library when running code through
12 |* the -insert-line-profiling LLVM pass.
14 \*===----------------------------------------------------------------------===*/
16 #include <stdlib.h>
17 #include <stdio.h>
18 #include <stdint.h>
20 #include "llvm/Support/DataTypes.h"
22 /* A file in this case is a translation unit. Each .o file built with line
23 * profiling enabled will emit to a different file. Only one file may be
24 * started at a time.
26 void llvm_prof_linectr_start_file(const char *orig_filename) {
27 printf("[%s]\n", orig_filename);
30 /* Emit data about a counter to the data file. */
31 void llvm_prof_linectr_emit_counter(const char *dir, const char *file,
32 uint32_t line, uint32_t column,
33 uint64_t *counter) {
34 printf("%s/%s:%u:%u %ull\n", dir, file, line, column,
35 (unsigned long long)(*counter));
38 void llvm_prof_linectr_end_file() {
39 printf("-----\n");