Skip to content
This repository has been archived by the owner on Nov 27, 2024. It is now read-only.

Commit

Permalink
Merge pull request #673 from OP2/connorjward/enable-loopy-caching
Browse files Browse the repository at this point in the history
Loopy caching fixes
  • Loading branch information
dham authored Oct 5, 2022
2 parents 3a1b62f + 0dcf7d6 commit a0259a9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 2 additions & 2 deletions pyop2/codegen/rep2loopy.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def generate_preambles(self, target):
pass

def with_types(self, arg_id_to_dtype, callables_table):
dtypes = OrderedDict()
dtypes = {}
for i in range(len(arg_id_to_dtype)):
if arg_id_to_dtype.get(i) is None:
# the types provided aren't mature enough to specialize the
Expand Down Expand Up @@ -416,7 +416,7 @@ def generate(builder, wrapper_name=None):
parameters.layer_end = builder.layer_extents[1].name
parameters.conditions = []
parameters.kernel_data = list(None for _ in parameters.wrapper_arguments)
parameters.temporaries = OrderedDict()
parameters.temporaries = {}
parameters.kernel_name = builder.kernel.name

# replace Materialise
Expand Down
4 changes: 0 additions & 4 deletions pyop2/op2.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@
from pyop2.parloop import (GlobalLegacyArg, DatLegacyArg, MixedDatLegacyArg, # noqa: F401
MatLegacyArg, MixedMatLegacyArg, LegacyParloop, ParLoop)

import loopy

__all__ = ['configuration', 'READ', 'WRITE', 'RW', 'INC', 'MIN', 'MAX',
'ON_BOTTOM', 'ON_TOP', 'ON_INTERIOR_FACETS', 'ALL',
Expand All @@ -70,9 +69,6 @@

_initialised = False

# turn off loopy caching because pyop2 kernels are cached already
loopy.set_caching_enabled(False)


def initialised():
"""Check whether PyOP2 has been yet initialised but not yet finalised."""
Expand Down

0 comments on commit a0259a9

Please sign in to comment.