Merge trunk version 204345 into gupc branch.
[official-gcc.git] / libgupc / include / gasp.h
blob0faaefca5afe4a52fb06ef3805aaa015225a60d4
1 /* Copyright (C) 2009-2013 Free Software Foundation, Inc.
2 This file is part of the UPC runtime library.
3 Written by Gary Funck <gary@intrepid.com>
4 and Nenad Vukicevic <nenad@intrepid.com>
6 This file is part of GCC.
8 GCC is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3, or (at your option)
11 any later version.
13 GCC is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 Under Section 7 of GPL version 3, you are granted additional
19 permissions described in the GCC Runtime Library Exception, version
20 3.1, as published by the Free Software Foundation.
22 You should have received a copy of the GNU General Public License and
23 a copy of the GCC Runtime Library Exception along with this program;
24 see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
25 <http://www.gnu.org/licenses/>. */
28 #ifndef _GASP_H_
29 #define _GASP_H_
31 #include <stdarg.h>
33 /* See GASP Specification (version 1.5)
34 http://gasp.hcs.ufl.edu/gasp-1.5-61606.pdf */
36 #define GASP_VERSION 20060914
38 typedef enum
40 GASP_MODEL_UPC,
41 GASP_MODEL_TITANIUM,
42 GASP_MODEL_CAF,
43 GASP_MODEL_MPI,
44 GASP_MODEL_SHMEM
45 } gasp_model_t;
47 typedef enum
49 GASP_START,
50 GASP_END,
51 GASP_ATOMIC,
52 } gasp_evttype_t;
54 struct _gasp_context_S;
55 typedef struct _gasp_context_S *gasp_context_t;
57 gasp_context_t gasp_init (gasp_model_t srcmodel, int *argc, char ***argv);
59 void gasp_event_notify (gasp_context_t context, unsigned int evttag,
60 gasp_evttype_t evttype, const char *filename,
61 int linenum, int colnum, ...);
63 void gasp_event_notifyVA (gasp_context_t context, unsigned int evttag,
64 gasp_evttype_t evttype, const char *filename,
65 int linenum, int colnum, va_list varargs);
67 int gasp_control (gasp_context_t context, int on);
69 unsigned int gasp_create_event (gasp_context_t context,
70 const char *name, const char *desc);
72 #endif /* _GASP_H_ */