OpenScop 0.9.7
scop.h
Go to the documentation of this file.
1/******************************************************************************
2 ** OpenScop Library **
3 **--------------------------------------------------------------------------**
4 ** scop.h **
5 **--------------------------------------------------------------------------**
6 ** First version: 30/04/2008 **
7 ******************************************************************************/
8
9/******************************************************************************
10 * OpenScop: Structures and formats for polyhedral tools to talk together *
11 ******************************************************************************
12 * ,___,,_,__,,__,,__,,__,,_,__,,_,__,,__,,___,_,__,,_,__, *
13 * / / / // // // // / / / // // / / // / /|,_, *
14 * / / / // // // // / / / // // / / // / / / /\ *
15 * |~~~|~|~~~|~~~|~~~|~~~|~|~~~|~|~~~|~~~|~~~|~|~~~|~|~~~|/_/ \ *
16 * | G |C| P | = | L | P |=| = |C| = | = | = |=| = |=| C |\ \ /\ *
17 * | R |l| o | = | e | l |=| = |a| = | = | = |=| = |=| L | \# \ /\ *
18 * | A |a| l | = | t | u |=| = |n| = | = | = |=| = |=| o | |\# \ \ *
19 * | P |n| l | = | s | t |=| = |d| = | = | = | | |=| o | | \# \ \ *
20 * | H | | y | | e | o | | = |l| | | = | | | | G | | \ \ \ *
21 * | I | | | | e | | | | | | | | | | | | | \ \ \ *
22 * | T | | | | | | | | | | | | | | | | | \ \ \ *
23 * | E | | | | | | | | | | | | | | | | | \ \ \ *
24 * | * |*| * | * | * | * |*| * |*| * | * | * |*| * |*| * | / \* \ \ *
25 * | O |p| e | n | S | c |o| p |-| L | i | b |r| a |r| y |/ \ \ / *
26 * '---'-'---'---'---'---'-'---'-'---'---'---'-'---'-'---' '--' *
27 * *
28 * Copyright (C) 2008 University Paris-Sud 11 and INRIA *
29 * *
30 * (3-clause BSD license) *
31 * Redistribution and use in source and binary forms, with or without *
32 * modification, are permitted provided that the following conditions *
33 * are met: *
34 * *
35 * 1. Redistributions of source code must retain the above copyright notice, *
36 * this list of conditions and the following disclaimer. *
37 * 2. Redistributions in binary form must reproduce the above copyright *
38 * notice, this list of conditions and the following disclaimer in the *
39 * documentation and/or other materials provided with the distribution. *
40 * 3. The name of the author may not be used to endorse or promote products *
41 * derived from this software without specific prior written permission. *
42 * *
43 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR *
44 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES *
45 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. *
46 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, *
47 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT *
48 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, *
49 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY *
50 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT *
51 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF *
52 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *
53 * *
54 * OpenScop Library, a library to manipulate OpenScop formats and data *
55 * structures. Written by: *
56 * Cedric Bastoul <Cedric.Bastoul@u-psud.fr> and *
57 * Louis-Noel Pouchet <Louis-Noel.pouchet@inria.fr> *
58 * *
59 ******************************************************************************/
60
61/******************************************************************************
62 * THIS FILE HAS BEEN AUTOMATICALLY GENERATED FROM scop.h.in BY configure *
63 ******************************************************************************/
64
65#ifndef OSL_SCOP_H
66#define OSL_SCOP_H
67
68#include <unistd.h>
69
70#define OSL_RELEASE "0.9.7"
71
72#include <osl/generic.h>
73#include <osl/interface.h>
74#include <osl/relation.h>
75#include <osl/statement.h>
76
77#if defined(__cplusplus)
78extern "C" {
79#endif
80
90struct osl_scop {
91 int version;
92 char* language;
93 osl_relation_p context;
94 osl_generic_p parameters;
95 osl_statement_p statement;
96 osl_interface_p registry;
97 osl_generic_p extension;
98 void* usr;
100 struct osl_scop* next;
101};
102typedef struct osl_scop osl_scop_t;
103typedef struct osl_scop* osl_scop_p;
104
105/******************************************************************************
106 * Structure display function *
107 ******************************************************************************/
108
109void osl_scop_idump(FILE*, const osl_scop_t*, int) OSL_NONNULL_ARGS(1);
110void osl_scop_dump(FILE*, const osl_scop_t*) OSL_NONNULL_ARGS(1);
111void osl_scop_print(FILE*, const osl_scop_t*) OSL_NONNULL_ARGS(1);
112
113// SCoPLib Compatibility
114void osl_scop_print_scoplib(FILE*, const osl_scop_t*) OSL_NONNULL_ARGS(1);
115
116/******************************************************************************
117 * Reading function *
118 ******************************************************************************/
119
120osl_scop_t* osl_scop_pread(FILE*, osl_interface_t*, int);
122
123/******************************************************************************
124 * Memory allocation/deallocation function *
125 ******************************************************************************/
126
127osl_scop_t* osl_scop_malloc(void) OSL_WARN_UNUSED_RESULT;
129
130/******************************************************************************
131 * Processing functions *
132 ******************************************************************************/
133
136osl_scop_t* osl_scop_clone(const osl_scop_t*) OSL_WARN_UNUSED_RESULT;
137osl_scop_t* osl_scop_remove_unions(const osl_scop_t*) OSL_WARN_UNUSED_RESULT;
143void osl_scop_get_attributes(const osl_scop_t*, int*, int*, int*, int*, int*);
145
146osl_names_t* osl_scop_names(const osl_scop_t* scop) OSL_WARN_UNUSED_RESULT;
147
148#if defined(__cplusplus)
149}
150#endif
151
152#endif /* define OSL_SCOP_H */
void osl_scop_idump(FILE *, const osl_scop_t *, int) OSL_NONNULL_ARGS(1)
void osl_scop_register_extension(osl_scop_t *, osl_interface_t *)
osl_scop_t * osl_scop_remove_unions(const osl_scop_t *) OSL_WARN_UNUSED_RESULT
struct osl_scop * osl_scop_p
Definition scop.h:103
void osl_scop_print(FILE *, const osl_scop_t *) OSL_NONNULL_ARGS(1)
osl_scop_t * osl_scop_pread(FILE *, osl_interface_t *, int)
void osl_scop_free(osl_scop_t *)
void osl_scop_dump(FILE *, const osl_scop_t *) OSL_NONNULL_ARGS(1)
bool osl_scop_equal(const osl_scop_t *, const osl_scop_t *)
void osl_scop_print_scoplib(FILE *, const osl_scop_t *) OSL_NONNULL_ARGS(1)
osl_scop_t * osl_scop_clone(const osl_scop_t *) OSL_WARN_UNUSED_RESULT
int osl_scop_check_compatible_scoplib(const osl_scop_t *)
int osl_scop_get_nb_parameters(const osl_scop_t *)
osl_names_t * osl_scop_names(const osl_scop_t *scop) OSL_WARN_UNUSED_RESULT
osl_scop_t * osl_scop_malloc(void) OSL_WARN_UNUSED_RESULT
osl_scop_t * osl_scop_read(FILE *)
int osl_scop_integrity_check(const osl_scop_t *)
void osl_scop_add(osl_scop_t **, osl_scop_t *)
void osl_scop_get_attributes(const osl_scop_t *, int *, int *, int *, int *, int *)
void osl_scop_normalize_scattering(osl_scop_t *)
size_t osl_scop_number(const osl_scop_t *)
osl_interface_p registry
Definition scop.h:96
osl_relation_p context
Definition scop.h:93
struct osl_scop * next
Definition scop.h:100
osl_statement_p statement
Definition scop.h:95
osl_generic_p extension
Definition scop.h:97
char * language
Definition scop.h:92
int version
Definition scop.h:91
void * usr
Definition scop.h:98
osl_generic_p parameters
Definition scop.h:94