-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathshm_count_info.h
More file actions
31 lines (23 loc) · 856 Bytes
/
shm_count_info.h
File metadata and controls
31 lines (23 loc) · 856 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
#ifndef __H_SHM_COUNT_INFO_HEADER_
#define __H_SHM_COUNT_INFO_HEADER_
extern int check_read_id(int id);
/**
*
* METHOD: get_op_total
* DESCRIPTION: get the total data process has read or writen
* @param : handle,the handle created
* @return : how many bytes process has read or writen
*/
unsigned long long get_op_total(void*handle);
/**
*
* METHOD: get_miss_stat
* DESCRIPTION: this function is used by write processto get a read process miss info
* @param : handle,the handle created
* @param : id, read process's id(not pid)
* @param : miss_block, output how many blocks the reader has missed
* @param : miss_bytes, output how many bytes the reader has missed
* @return : SHM_OK if success,SHM_FAIL if fail
*/
int get_miss_stat(void*handle, int id, unsigned long long *miss_block, unsigned long long *miss_bytes);
#endif