mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-16 05:54:34 +03:00
Add IPC performance counter for Linux
This commit is contained in:
@ -10,11 +10,14 @@ in the source distribution for its full text.
|
||||
*/
|
||||
|
||||
|
||||
#include "PerfCounter.h"
|
||||
|
||||
#define PROCESS_FLAG_LINUX_IOPRIO 0x0100
|
||||
#define PROCESS_FLAG_LINUX_OPENVZ 0x0200
|
||||
#define PROCESS_FLAG_LINUX_VSERVER 0x0400
|
||||
#define PROCESS_FLAG_LINUX_CGROUP 0x0800
|
||||
#define PROCESS_FLAG_LINUX_OOM 0x1000
|
||||
#define PROCESS_FLAG_LINUX_HPC 0x2000
|
||||
|
||||
typedef enum UnsupportedProcessFields {
|
||||
FLAGS = 9,
|
||||
@ -78,7 +81,10 @@ typedef enum LinuxProcessFields {
|
||||
PERCENT_IO_DELAY = 117,
|
||||
PERCENT_SWAP_DELAY = 118,
|
||||
#endif
|
||||
LAST_PROCESSFIELD = 119,
|
||||
#ifdef HAVE_PERFCOUNTERS
|
||||
IPC = 119,
|
||||
#endif
|
||||
LAST_PROCESSFIELD = 120,
|
||||
} LinuxProcessField;
|
||||
|
||||
#include "IOPriority.h"
|
||||
@ -131,6 +137,11 @@ typedef struct LinuxProcess_ {
|
||||
float blkio_delay_percent;
|
||||
float swapin_delay_percent;
|
||||
#endif
|
||||
#ifdef HAVE_PERFCOUNTERS
|
||||
PerfCounter* cycleCounter;
|
||||
PerfCounter* insnCounter;
|
||||
double ipc;
|
||||
#endif
|
||||
} LinuxProcess;
|
||||
|
||||
#ifndef Process_isKernelThread
|
||||
|
Reference in New Issue
Block a user