libspe2  0.9a
speevent.h
Go to the documentation of this file.
1 /*
2  * libspe2 - A wrapper library to adapt the JSRE SPU usage model to SPUFS
3  * Copyright (C) 2005 IBM Corp.
4  *
5  * This library is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU Lesser General Public License as published by
7  * the Free Software Foundation; either version 2.1 of the License,
8  * or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful, but
11  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12  * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
13  * License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with this library; if not, write to the Free Software Foundation,
17  * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18  */
19 
20 
21 
22 #ifndef _SPEEVENT_H_
23 #define _SPEEVENT_H_
24 
25 #include "spebase.h"
26 
27 /* private constants */
32 };
33 
34 /* private types */
35 typedef struct spe_context_event_priv
36 {
37  pthread_mutex_t lock;
38  pthread_mutex_t stop_event_read_lock;
42 
43 
45 
46 /*
47  * spe_event_handler_create
48  */
49 
51 
52 /*
53  * spe_event_handler_destroy
54  */
55 
57 
58 /*
59  * spe_event_handler_register
60  */
61 
63 
64 /*
65  * spe_event_handler_deregister
66  */
67 
69 
70 /*
71  * spe_event_wait
72  */
73 
74 int _event_spe_event_wait(spe_event_handler_ptr_t evhandler, spe_event_unit_t *events, int max_events, int timeout);
75 
77 
79 
80 int _event_spe_context_run (spe_context_ptr_t spe, unsigned int *entry, unsigned int runflags, void *argp, void *envp, spe_stop_info_t *stopinfo);
81 
84 
85 #endif /*SPEEVENT_H_*/