OPAL (Object Oriented Parallel Accelerator Library)  2.2.0
OPAL
RNGAssignDefs.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /***************************************************************************
3  *
4  * The IPPL Framework
5  *
6  *
7  * Visit http://people.web.psi.ch/adelmann/ for more details
8  *
9  ***************************************************************************/
10 
11 #ifndef RNG_ASSIGN_DEFS_H
12 #define RNG_ASSIGN_DEFS_H
13 
14 // include files
15 #include "PETE/IpplExpressions.h"
16 #include "Field/AssignTags.h"
17 
18 
19 // interactions for basic tags
20 
22 //
23 // Evaluation functor.
24 //
26 
27 template<class GT>
28 inline typename SequenceGen<GT>::Return_t
30 {
31  return p();
32 }
33 
35 //
36 // Count the elements in an expression.
37 //
39 
40 template<class GT, class C>
41 inline int
43 {
44  // just return a code value
45  return -1;
46 }
47 
49 //
50 // Increment the pointers in an expression.
51 //
53 
54 template<class GT, class C>
55 inline int
57 {
58  // just return (increment happens automatically after evaluation!)
59  return 0;
60 }
61 
62 
63 // Field-specific tag interactions
64 
65 
67 //
68 // Go to beginning of LField
69 //
71 
72 template<class GT, class C>
73 inline int
75 {
76  // just return
77  return 0;
78 }
79 
81 //
82 // Go on to the next LField
83 //
85 
86 template<class GT, class C>
87 inline int
89 {
90  // just return
91  return 0;
92 }
93 
94 //
95 // If there is an RNG in the expr, it can't have the same ID.
96 //
97 template<class GT, class C>
98 inline bool
100 {
101  return false;
102 }
103 
104 //
105 // for plugbase, just return true for RNG
106 //
107 template <unsigned D> struct PlugBase;
108 
109 template<class GT, class C, unsigned D>
110 inline bool
112 {
113  return true;
114 }
115 
116 //
117 // RNG objects are not compressed!
118 //
119 template<class GT, class C>
120 inline bool
122 {
123  return false;
124 }
125 
127 //
128 // Evaluation functors with arguments
129 //
131 
132 template<class GT>
133 inline typename SequenceGen<GT>::Return_t
135 {
136  return p();
137 }
138 
139 template<class GT>
140 inline typename SequenceGen<GT>::Return_t
142 {
143  return p();
144 }
145 
146 template<class GT>
147 inline typename SequenceGen<GT>::Return_t
149 {
150  return p();
151 }
152 
153 //
154 // Does it have unit stride?
155 // Not really a sensible question, but it is safe to say it does.
156 //
157 
158 template<class GT, class C>
159 inline bool
161 {
162  return true;
163 }
164 
165 
166 //
167 // RNG ignores step functor
168 //
169 template<class GT, class C>
170 inline int
172 {
173  return 0;
174 }
175 
176 //
177 // RNG ignores rewind functor
178 //
179 template<class GT, class C>
180 inline int
182 {
183  return 0;
184 }
185 
186 // RNG ignores filling guard cells question
187 template<class GT, class C, unsigned int D, class T1>
188 inline int
190  const FillGCIfNecessaryTag<D,T1> &, C)
191 {
192  return 0;
193 }
194 
195 
196 #endif // RNG_ASSIGN_DEFS_H
197 
198 /***************************************************************************
199  * $RCSfile: RNGAssignDefs.h,v $ $Author: adelmann $
200  * $Revision: 1.1.1.1 $ $Date: 2003/01/23 07:40:33 $
201  * IPPL_VERSION_ID: $Id: RNGAssignDefs.h,v 1.1.1.1 2003/01/23 07:40:33 adelmann Exp $
202  ***************************************************************************/
203 
GT::Return_t Return_t
Definition: SequenceGen.h:89
bool for_each(const BareFieldIterator< T, D > &p, SameFieldID s, C)
Definition: AssignDefs.h:30