Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
pystencils
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pycodegen
pystencils
Commits
8bf8628e
Commit
8bf8628e
authored
2 years ago
by
Philipp Suffa
Browse files
Options
Downloads
Patches
Plain Diff
small change in kernelcreation to allow absolut access only kernels on GPU
parent
5e2037dd
No related branches found
No related tags found
No related merge requests found
Pipeline
#51597
failed
1 year ago
Stage: pretest
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
pystencils/gpucuda/kernelcreation.py
+4
-2
4 additions, 2 deletions
pystencils/gpucuda/kernelcreation.py
with
4 additions
and
2 deletions
pystencils/gpucuda/kernelcreation.py
+
4
−
2
View file @
8bf8628e
...
...
@@ -45,12 +45,14 @@ def create_cuda_kernel(assignments: Union[AssignmentCollection, NodeCollection],
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
)
if
iteration_slice
is
None
:
# determine iteration slice from ghost layers
if
ghost_layers
is
None
:
# determine required number of ghost layers from field access
required_ghost_layers
=
max
([
fa
.
required_ghost_layers
for
fa
in
field_accesses
])
if
len
(
field_accesses
)
==
0
:
required_ghost_layers
=
0
else
:
required_ghost_layers
=
max
([
fa
.
required_ghost_layers
for
fa
in
field_accesses
])
ghost_layers
=
[(
required_ghost_layers
,
required_ghost_layers
)]
*
len
(
common_shape
)
iteration_slice
=
[]
if
isinstance
(
ghost_layers
,
int
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment