Skip to content
Snippets Groups Projects
Commit ac4b31c1 authored by Christoph Alt's avatar Christoph Alt
Browse files

Updated import to new pystencils api

parent 96c63098
No related branches found
No related tags found
1 merge request!1Add CUDA support
......@@ -6,10 +6,10 @@ from jinja2 import Environment, PackageLoader, StrictUndefined
from pystencils.backends.cbackend import generate_c, get_headers
from pystencils.astnodes import KernelFunction
from pystencils.enums import Backend
from pystencils.data_types import get_base_type
from pystencils.typing import get_base_type
from pystencils.sympyextensions import prod
from pystencils.transformations import get_common_shape
from pystencils.gpucuda import BlockIndexing
from pystencils.transformations import get_common_field
# from pystencils.gpucuda import BlockIndexing
from pystencils_benchmark.enums import Compiler
......@@ -121,7 +121,7 @@ def kernel_main(kernels_ast: List[KernelFunction], timing: bool = True, cuda_blo
fields.append((p.field_name, dtype, elements))
call_parameters.append(p.field_name)
common_shape = get_common_shape(kernel.fields_accessed)
common_shape = get_common_field(kernel.fields_accessed).shape
indexing = kernel.indexing
block_and_thread_numbers = indexing.call_parameters(common_shape)
block_and_thread_numbers['block'] = tuple(int(i) for i in block_and_thread_numbers['block'])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment