diff --git a/loopy/kernel.py b/loopy/kernel.py index 8702883dbea920d960be8139de2df2a6170791b5..4ca9b5540b05c0abb0808d7933b365d3cb023b9b 100644 --- a/loopy/kernel.py +++ b/loopy/kernel.py @@ -128,13 +128,17 @@ class ArrayArg: from pymbolic import parse strides = parse(strides) - strides = tuple(strides) + if not isinstance(shape, tuple): + shape = (shape,) if shape is not None: if isinstance(shape, str): from pymbolic import parse shape = parse(shape) + if not isinstance(shape, tuple): + shape = (shape,) + from pyopencl.compyte.array import ( f_contiguous_strides, c_contiguous_strides)