Skip to content
Snippets Groups Projects
Commit 22407db2 authored by Dominic Kempf's avatar Dominic Kempf
Browse files

Use the new iname duplication strategies!

parent 69b71f66
No related branches found
No related tags found
No related merge requests found
......@@ -204,6 +204,13 @@ def generate_kernel(integrals):
kernel = preprocess_kernel(kernel)
# see whether we need iname duplication to make this thing schedulable!
# TODO: Use a clever strategy here, instead of random transformation until the problem is resolved
from loopy import needs_iname_duplication, get_iname_duplication_options, duplicate_inames
while needs_iname_duplication(kernel):
inames, within = next(get_iname_duplication_options(kernel))
kernel = duplicate_inames(kernel, inames, within)
# Loopy might have introduced some temporary variables during preprocessing. As I want to have my own
# temporary declaration code right now, I call the declaration preamble manually.
for added_tv in set(kernel.temporary_variables.keys()) - set(temporaries.keys()):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment