1717
1818
1919# Expression kernel description type
20- ExpressionKernel = namedtuple ('ExpressionKernel' , ['ast' , 'oriented' , 'needs_cell_sizes' , 'coefficients' , 'tabulations' ])
20+ ExpressionKernel = namedtuple ('ExpressionKernel' , ['ast' , 'oriented' , 'needs_cell_sizes' , 'coefficients' , 'first_coefficient_fake_coords' , ' tabulations' ])
2121
2222
2323def make_builder (* args , ** kwargs ):
@@ -153,12 +153,14 @@ def register_requirements(self, ir):
153153 provided by the kernel interface."""
154154 self .oriented , self .cell_sizes , self .tabulations = check_requirements (ir )
155155
156- def construct_kernel (self , return_arg , impero_c , index_names ):
156+ def construct_kernel (self , return_arg , impero_c , index_names , first_coefficient_fake_coords ):
157157 """Constructs an :class:`ExpressionKernel`.
158158
159159 :arg return_arg: loopy.GlobalArg for the return value
160160 :arg impero_c: gem.ImperoC object that represents the kernel
161161 :arg index_names: pre-assigned index names
162+ :arg first_coefficient_fake_coords: If true, the kernel's first
163+ coefficient is a constructed UFL coordinate field
162164 :returns: :class:`ExpressionKernel` object
163165 """
164166 args = [return_arg ]
@@ -173,7 +175,8 @@ def construct_kernel(self, return_arg, impero_c, index_names):
173175 loopy_kernel = generate_loopy (impero_c , args , self .scalar_type ,
174176 "expression_kernel" , index_names )
175177 return ExpressionKernel (loopy_kernel , self .oriented , self .cell_sizes ,
176- self .coefficients , self .tabulations )
178+ self .coefficients , first_coefficient_fake_coords ,
179+ self .tabulations )
177180
178181
179182class KernelBuilder (KernelBuilderBase ):
0 commit comments