Blame src/perfctr-2.6.x/examples/perfex/arch.h

Packit Service a1973e
/* $Id: arch.h,v 1.2.2.3 2010/06/08 20:48:55 mikpe Exp $
Packit Service a1973e
 * Architecture-specific support code.
Packit Service a1973e
 *
Packit Service a1973e
 * Copyright (C) 2004-2010  Mikael Pettersson
Packit Service a1973e
 */
Packit Service a1973e
Packit Service a1973e
#define ARRAY_SIZE(x)	(sizeof(x) / sizeof((x)[0]))
Packit Service a1973e
Packit Service a1973e
extern void do_print(FILE *resfile,
Packit Service a1973e
		     const struct perfctr_info *info,
Packit Service a1973e
		     const struct perfctr_cpu_control *cpu_control,
Packit Service a1973e
		     const struct perfctr_sum_ctrs *sum);
Packit Service a1973e
Packit Service a1973e
extern void do_arch_usage(void);
Packit Service a1973e
Packit Service a1973e
/* Hack while phasing out an old number parsing bug. */
Packit Service a1973e
extern unsigned long my_strtoul(const char *nptr, char **endptr);
Packit Service a1973e
Packit Service a1973e
extern unsigned int do_event_spec(unsigned int n,
Packit Service a1973e
				  const char *arg,
Packit Service a1973e
				  struct perfctr_cpu_control *cpu_control);
Packit Service a1973e
Packit Service a1973e
extern int do_arch_option(int ch,
Packit Service a1973e
			  const char *arg,
Packit Service a1973e
			  struct perfctr_cpu_control *cpu_control);
Packit Service a1973e
Packit Service a1973e
#if defined(__i386__) || defined(__x86_64__)
Packit Service a1973e
#include "x86.h"
Packit Service a1973e
#elif defined(__powerpc__)
Packit Service a1973e
#include "ppc.h"
Packit Service a1973e
#elif defined(__arm__)
Packit Service a1973e
#include "arm.h"
Packit Service a1973e
#endif