Commit 6bd1cf86 authored by Dominik Thoennes's avatar Dominik Thoennes

different approach

parent 689ac4df
Pipeline #22651 passed with stages
in 188 minutes and 58 seconds
......@@ -265,9 +265,6 @@ def generate_call(ctx, kernel_info, ghost_layers_to_include=0, cell_interval=Non
kernel_call_lines.append("const %s %s = %s;" % (type_str, param.symbol.name, shape))
call_parameters = ", ".join([p.symbol.name for p in ast_params])
# this is a hack and will break if omega is called something else
call_parameters = re.sub(r'(omega)([^_]|$)', r'\1_\2', call_parameters)
call_parameters = re.sub(r', h$', r', h_', call_parameters)
if not is_cpu:
if not spatial_shape_symbols:
......
......@@ -58,6 +58,7 @@ namespace {{namespace}} {
void {{class_name}}::operator()( IBlock * block{%if target is equalto 'gpu'%} , cudaStream_t stream{% endif %} )
{
{{kernel|generate_block_data_to_field_extraction|indent(4)}}
{{kernel|generate_refs_for_kernel_parameters(prefix='this->', parameters_to_ignore=['velocity', 'src', 'src_tmp', 'pdfs', 'pdfs_tmp'])|indent(4) }}
{{kernel|generate_call(stream='stream')|indent(4)}}
{{kernel|generate_swaps|indent(4)}}
}
......@@ -77,6 +78,7 @@ void {{class_name}}::runOnCellInterval( const shared_ptr<StructuredBlockStorage>
return;
{{kernel|generate_block_data_to_field_extraction|indent(4)}}
{{kernel|generate_refs_for_kernel_parameters(prefix='this->', parameters_to_ignore=['velocity', 'src', 'src_tmp', 'pdfs', 'pdfs_tmp'])|indent(4) }}
{{kernel|generate_call(stream='stream', cell_interval='ci')|indent(4)}}
{{kernel|generate_swaps|indent(4)}}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment