From c095ee4f1a0f3a842fbe1dc8ea864c0d4f2c7fb3 Mon Sep 17 00:00:00 2001 From: Stephan Seitz <stephan.seitz@fau.de> Date: Fri, 27 Sep 2019 16:39:40 +0200 Subject: [PATCH] Bugfix: Align calculation of number of ghost layers on GPU with CPU version For the calculation of the number of ghostlayers only relative accesses should be considered like on the CPU version --- pystencils/gpucuda/kernelcreation.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pystencils/gpucuda/kernelcreation.py b/pystencils/gpucuda/kernelcreation.py index ed916d54b..4430abba6 100644 --- a/pystencils/gpucuda/kernelcreation.py +++ b/pystencils/gpucuda/kernelcreation.py @@ -27,6 +27,7 @@ def create_cuda_kernel(assignments, num_buffer_accesses = 0 for eq in assignments: field_accesses.update(eq.atoms(Field.Access)) + field_accesses = {e for e in field_accesses if not e.is_absolute_access} num_buffer_accesses += sum(1 for access in eq.atoms(Field.Access) if FieldType.is_buffer(access.field)) common_shape = get_common_shape(fields_without_buffers) -- GitLab