memstatdump.h
1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
* Copyright (C) 1996-1998 by the Board of Trustees
* of Leland Stanford Junior University.
*
* This file is part of the SimOS distribution.
* See LICENSE file for terms of the license.
*
*/
/*****************************************************************
* memstatdump.h
*
* Reads the memstat.output* files
*
* Author: $bugnion$
* Date: $$
*******************************************************************/
#ifndef MEMSTATDUMP_H
#define MEMSTATDUMP_H
#define MEMSTAT_TYPES_ONLY
#include <stdio.h>
#include "../../../common/stats/simrecord.h"
typedef enum {
Low, /* 4 MB bucket */
High, /* cache line buckets */
Detail /* word size buckets */
} Resolution;
extern SimRecHeader msHeader;
#define MEMSTAT_COUNTER sizeof(MemStatCounter)
int MemStatFileOpen(char *filename);
void MemStatFileIterate( void (*process)(VA addr,void *,Resolution));
void MemStatDiff(char *file1,char *file2, char *file3);
int GetLineFromFile(FILE *f, char *buf,int len);
#endif