* config/mips/mips.md (length): Don't use mips_fetch_insns for indexed
[official-gcc.git] / libbanshee / engine / flowrow-sort.h
blob8d79b42c29da2d928dd38dfe866c1cf92fd6b5f8
1 /*
2 * Copyright (c) 2000-2001
3 * The Regents of the University of California. All rights reserved.
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright
11 * notice, this list of conditions and the following disclaimer in the
12 * documentation and/or other materials provided with the distribution.
13 * 3. Neither the name of the University nor the names of its contributors
14 * may be used to endorse or promote products derived from this software
15 * without specific prior written permission.
17 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
18 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
31 #ifndef FLOWROW_SORT_H
32 #define FLOWROW_SORT_H
35 #include "stdio.h"
36 #include "banshee.h"
37 #include "termhash.h"
38 #include "flow-var.h"
40 struct flowrow_field
42 char *label;
43 gen_e expr;
46 typedef struct flowrow_field *flowrow_field;
48 DECLARE_LIST(flowrow_map,flowrow_field)
50 extern region flowrow_region;
52 void flowrow_inclusion(fresh_fn_ptr fresh, get_stamp_fn_ptr get_stamp,
53 incl_fn_ptr field_incl,gen_e zero_elem, gen_e e1,
54 gen_e e2) deletes;
56 gen_e flowrow_row(get_stamp_fn_ptr get_stamp,flowrow_map fields, gen_e rest) deletes;
58 gen_e flowrow_extract_field(const char *name, gen_e e);
59 gen_e flowrow_extract_rest(gen_e e);
60 flowrow_map flowrow_extract_fields(gen_e e);
62 stamp flowrow_get_stamp(gen_e e);
64 #ifndef NONSPEC
65 gen_e flowrow_zero(void);
66 gen_e flowrow_one(void);
67 gen_e flowrow_abs(void);
68 gen_e flowrow_wild(void);
69 gen_e flowrow_fresh(const char *name);
70 gen_e flowrow_fresh_small(const char *name);
71 gen_e flowrow_fresh_large(const char *name);
72 #else
73 sort_kind flowrow_base_sort(gen_e e);
74 gen_e flowrow_zero(sort_kind base_sort);
75 gen_e flowrow_one(sort_kind base_sort);
76 gen_e flowrow_abs(sort_kind base_sort);
77 gen_e flowrow_wild(sort_kind base_sort);
78 gen_e flowrow_fresh(sort_kind base_sort);
79 gen_e flowrow_fresh_small(sort_kind base_sort);
80 gen_e flowrow_fresh_large(sort_kind base_sort);
81 #endif
83 bool flowrow_is_zero(gen_e e);
84 bool flowrow_is_one(gen_e e);
85 bool flowrow_is_abs(gen_e e);
86 bool flowrow_is_wild(gen_e e);
87 bool flowrow_is_var(gen_e e);
88 bool flowrow_is_row(gen_e e);
89 bool flowrow_is_alias(gen_e e);
92 void flowrow_init(void);
93 void flowrow_reset(void) deletes;
95 typedef void (* field_print_fn_ptr) (FILE *f,gen_e e) deletes;
97 void flowrow_print(FILE *f,get_stamp_fn_ptr get_stamp,
98 field_print_fn_ptr field_print,gen_e e) deletes;
99 void flowrow_print_stats(FILE *f);
101 extern struct flowrow_stats flowrow_stats;
103 struct flowrow_stats
105 int fresh;
106 int fresh_small;
107 int fresh_large;
109 int rows_disjoint_wild;
110 int rows_equal;
111 int rows_zero_one_wild;
112 int rows_l_inductive;
113 int rows_r_inductive;
114 int rows_disjoint_r1_minimal;
115 int rows_disjoint_r1_var_r2_minimal;
116 int rows_disjoint_r1_var_r2_maximal;
117 int rows_disjoint_r1_var_r2_closed;
118 int rows_disjoint_r1_var_r2_var_lt;
119 int rows_disjoint_r1_var_r2_var_gt;
120 int rows_equal_domains;
121 int rows_nonempty_intersection;
122 int rows_fresh;
123 int rows_fresh_large;
126 #endif /* FLOWROW_H */