Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

adjust structure

git-svn-id: http://svn.coderepos.org/share/lang/c/picoev/trunk@35009 d0d07461-0603-4401-acd4-de1884942a52
  • Loading branch information...
commit b1b872d656b3cbaf392fe20a520a793a187e96ff 1 parent 320666f
kazuho authored
Showing with 5 additions and 4 deletions.
  1. +5 −4 picoev.h
View
9 picoev.h
@@ -65,7 +65,7 @@ extern "C" {
#define PICOEV_WRITE 2
#define PICOEV_TIMEOUT 4
- typedef unsigned int picoev_loop_id_t;
+ typedef unsigned short picoev_loop_id_t;
typedef struct picoev_loop_st picoev_loop;
@@ -74,12 +74,13 @@ extern "C" {
typedef struct picoev_fd_st {
/* use accessors! */
- /* should keep the size to 16 bytes on 32-bit arch, 32 bytes on 64-bit */
+ /* TODO adjust the size to match that of a cache line */
picoev_handler* callback;
void* cb_arg;
picoev_loop_id_t loop_id;
- short events;
- short timeout_idx; /* -1 if not used, otherwise index of timeout_vec */
+ char events;
+ unsigned char timeout_idx; /* -1 if not used */
+ int __link_fd;
} picoev_fd;
struct picoev_loop_st {
Please sign in to comment.
Something went wrong with that request. Please try again.