Blame src/libpfm-3.y/lib/pfmlib_coreduo_priv.h

Packit Service a1973e
/*
Packit Service a1973e
 * Copyright (c) 2009 Google, Inc
Packit Service a1973e
 * Contributed by Stephane Eranian <eranian@gmail.com>
Packit Service a1973e
 *
Packit Service a1973e
 * Based on:
Packit Service a1973e
 * Copyright (c) 2006 Hewlett-Packard Development Company, L.P.
Packit Service a1973e
 * Contributed by Stephane Eranian <eranian@hpl.hp.com>
Packit Service a1973e
 *
Packit Service a1973e
 * Permission is hereby granted, free of charge, to any person obtaining a copy
Packit Service a1973e
 * of this software and associated documentation files (the "Software"), to deal
Packit Service a1973e
 * in the Software without restriction, including without limitation the rights
Packit Service a1973e
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
Packit Service a1973e
 * of the Software, and to permit persons to whom the Software is furnished to do so,
Packit Service a1973e
 * subject to the following conditions:
Packit Service a1973e
 *
Packit Service a1973e
 * The above copyright notice and this permission notice shall be included in all
Packit Service a1973e
 * copies or substantial portions of the Software.
Packit Service a1973e
 *
Packit Service a1973e
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
Packit Service a1973e
 * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
Packit Service a1973e
 * PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
Packit Service a1973e
 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
Packit Service a1973e
 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
Packit Service a1973e
 * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Packit Service a1973e
 */
Packit Service a1973e
#ifndef __PFMLIB_COREDUO_PRIV_H__
Packit Service a1973e
#define __PFMLIB_COREDUO_PRIV_H__
Packit Service a1973e
Packit Service a1973e
#define PFMLIB_COREDUO_MAX_UMASK 16
Packit Service a1973e
Packit Service a1973e
typedef struct {
Packit Service a1973e
	char			*pme_uname; /* unit mask name */
Packit Service a1973e
	char			*pme_udesc; /* event/umask description */
Packit Service a1973e
	unsigned int		pme_ucode;  /* unit mask code */
Packit Service a1973e
	unsigned int		pme_flags;  /* unit mask flags */
Packit Service a1973e
} pme_coreduo_umask_t;
Packit Service a1973e
Packit Service a1973e
typedef struct {
Packit Service a1973e
	char			*pme_name;	/* event name */
Packit Service a1973e
	char			*pme_desc;	/* event description */
Packit Service a1973e
	unsigned int		pme_code; 	/* event code */
Packit Service a1973e
	unsigned int		pme_numasks;	/* number of umasks */
Packit Service a1973e
	unsigned int		pme_flags;	/* flags */
Packit Service a1973e
	pme_coreduo_umask_t	pme_umasks[PFMLIB_COREDUO_MAX_UMASK]; /* umask desc */
Packit Service a1973e
} pme_coreduo_entry_t;
Packit Service a1973e
Packit Service a1973e
/*
Packit Service a1973e
 * pme_flags value (event and unit mask)
Packit Service a1973e
 */
Packit Service a1973e
Packit Service a1973e
/* event-level constraints */
Packit Service a1973e
#define PFMLIB_COREDUO_CSPEC		0x02 /* requires a core specification */
Packit Service a1973e
#define PFMLIB_COREDUO_PMC0		0x04 /* works only on IA32_PMC0  */
Packit Service a1973e
#define PFMLIB_COREDUO_PMC1		0x08 /* works only on IA32_PMC1 */
Packit Service a1973e
#define PFMLIB_COREDUO_MESI		0x10 /* requires MESI */
Packit Service a1973e
Packit Service a1973e
#endif /* __PFMLIB_COREDUO_PRIV_H__ */