support PERF_TYPE_{HARDWARE|HW_CACHE} in perf_event_open

refs #829
This commit is contained in:
Ken Sato
2017-10-12 16:51:47 +09:00
parent 2ae6883a8b
commit 12840601e1
15 changed files with 685 additions and 51 deletions

View File

@ -26,6 +26,7 @@
#include <syscall.h>
#include <bitops.h>
#include <profile.h>
#include <config.h>
#define VR_NONE 0x0
#define VR_STACK 0x1
@ -691,6 +692,10 @@ struct thread {
int mod_clone;
struct uti_attr *mod_clone_arg;
int parent_cpuid;
// for performance counter
unsigned long pmc_alloc_map;
unsigned long extra_reg_alloc_map;
};
#define VM_RANGE_CACHE_SIZE 4