/[escript]/trunk/paso/src/Pattern.h
ViewVC logotype

Annotation of /trunk/paso/src/Pattern.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2548 - (hide annotations)
Mon Jul 20 06:20:06 2009 UTC (10 years, 4 months ago) by jfenwick
File MIME type: text/plain
File size: 3062 byte(s)
Updating copyright notices
1 ksteube 1313
2     /*******************************************************
3 ksteube 1811 *
4 jfenwick 2548 * Copyright (c) 2003-2009 by University of Queensland
5 ksteube 1811 * Earth Systems Science Computational Center (ESSCC)
6     * http://www.uq.edu.au/esscc
7     *
8     * Primary Business: Queensland, Australia
9     * Licensed under the Open Software License version 3.0
10     * http://www.opensource.org/licenses/osl-3.0.php
11     *
12     *******************************************************/
13 ksteube 1313
14 ksteube 1811
15 ksteube 1313 /**************************************************************/
16    
17     /* Paso: pattern */
18    
19     /**************************************************************/
20    
21     /* Author: gross@access.edu.au */
22    
23     /**************************************************************/
24    
25     #ifndef INC_PASO_PATTERN
26     #define INC_PASO_PATTERN
27    
28     #include "Common.h"
29    
30     /**************************************************************/
31    
32     #define PATTERN_FORMAT_DEFAULT 0
33     #define PATTERN_FORMAT_SYM 1
34     #define PATTERN_FORMAT_OFFSET1 2
35    
36     typedef struct Paso_Pattern {
37     int type;
38     dim_t numOutput;
39     dim_t numInput;
40     dim_t input_block_size; /* logical block size in the input */
41     dim_t output_block_size; /* logical block size in the output */
42     dim_t block_size; /* = input_block_size * output_block_size */
43    
44     dim_t len;
45     index_t* ptr;
46     index_t* index;
47     dim_t reference_counter;
48     } Paso_Pattern;
49    
50 artak 1881 #define INDEXLIST_LENGTH 85
51    
52     typedef struct Paso_IndexList {
53     index_t index[INDEXLIST_LENGTH];
54     dim_t n;
55     struct Paso_IndexList *extension;
56     } Paso_IndexList;
57 ksteube 1313 /* interfaces: */
58    
59 phornby 2071
60     PASO_DLL_API
61 gross 1736 Paso_Pattern* Paso_Pattern_alloc(int type, dim_t input_block_size, dim_t output_block_size, dim_t numOutput, dim_t numInput, index_t* ptr, index_t* index);
62 phornby 2071
63     PASO_DLL_API
64    
65     PASO_DLL_API
66 ksteube 1313 Paso_Pattern* Paso_Pattern_getReference(Paso_Pattern*);
67 phornby 2071
68     PASO_DLL_API
69 ksteube 1313 void Paso_Pattern_free(Paso_Pattern*);
70 phornby 2071
71     PASO_DLL_API
72 ksteube 1313 int Paso_comparIndex(const void *,const void *);
73 phornby 2071
74     PASO_DLL_API
75 ksteube 1313 Paso_Pattern* Paso_Pattern_unrollBlocks(Paso_Pattern*,int, dim_t,dim_t);
76 phornby 2071
77     PASO_DLL_API
78 ksteube 1313 Paso_Pattern* Paso_Pattern_getSubpattern(Paso_Pattern*,dim_t,dim_t,index_t*,index_t*);
79 phornby 2071
80     PASO_DLL_API
81 ksteube 1313 bool_t Paso_Pattern_isEmpty(Paso_Pattern* in);
82 phornby 2071
83     PASO_DLL_API
84 ksteube 1313 void Paso_Pattern_mis(Paso_Pattern* pattern_p, index_t* mis_marker);
85 phornby 2071
86     PASO_DLL_API
87 ksteube 1313 void Paso_Pattern_reduceBandwidth(Paso_Pattern* self,index_t* oldToNew);
88 phornby 2071
89     PASO_DLL_API
90 gross 1361 void Paso_Pattern_color(Paso_Pattern* patter, index_t* num_colors, index_t* colorOf);
91 artak 1881 Paso_Pattern* Paso_Pattern_multiply(int type, Paso_Pattern* A, Paso_Pattern* B);
92 phornby 2071
93     PASO_DLL_API
94 artak 1881 Paso_Pattern* Paso_Pattern_binop(int type, Paso_Pattern* A, Paso_Pattern* B);
95 ksteube 1313
96 phornby 2071
97     PASO_DLL_API
98 artak 1881 void Paso_IndexList_insertIndex(Paso_IndexList*, index_t);
99 phornby 2071
100     PASO_DLL_API
101 artak 1881 void Paso_IndexList_toArray(Paso_IndexList*, index_t*, index_t, index_t, index_t);
102 phornby 2071
103     PASO_DLL_API
104 artak 1881 dim_t Paso_IndexList_count(Paso_IndexList*, index_t, index_t);
105 phornby 2071
106     PASO_DLL_API
107 artak 1881 void Paso_IndexList_free(Paso_IndexList*);
108 phornby 2071
109     PASO_DLL_API
110 artak 1881 Paso_Pattern* Paso_IndexList_createPattern(dim_t n0, dim_t n,Paso_IndexList* index_list,index_t range_min,index_t range_max, index_t index_offset);
111    
112 ksteube 1313 #endif /* #ifndef INC_PASO_SYSTEMPATTERN */

  ViewVC Help
Powered by ViewVC 1.1.26