From 12e15377faaebde3152a67055303b19cd6d63573 Mon Sep 17 00:00:00 2001
From: Andreas Kloeckner <inform@tiker.net>
Date: Thu, 4 Oct 2012 20:02:16 -0400
Subject: [PATCH] Use specified allocator in CompiledKernel.__call__.

---
 loopy/compiled.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/loopy/compiled.py b/loopy/compiled.py
index 3051b854e..41f401426 100644
--- a/loopy/compiled.py
+++ b/loopy/compiled.py
@@ -194,7 +194,8 @@ class CompiledKernel:
                 alloc_size = sum(astrd*(alen-1)
                         for alen, astrd in zip(shape, numpy_strides)) + 1
 
-                storage = cl_array.empty(queue, alloc_size, arg.dtype)
+                storage = cl_array.empty(queue, alloc_size, arg.dtype,
+                        allocator=allocator)
                 val = cl_array.as_strided(storage, shape, numpy_strides)
             else:
                 assert _arg_matches_spec(arg, val, kwargs)
-- 
GitLab