summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gpu.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/gpu.py b/gpu.py
index 16e6f4a..fbf1fef 100644
--- a/gpu.py
+++ b/gpu.py
@@ -72,6 +72,9 @@ class GPU(object):
device = cuda.Device(device_id)
self.context = device.make_context()
print 'device %s' % self.context.get_device().name()
+
+ self.context.set_cache_config(cuda.func_cache.PREFER_L1)
+
cuda_options = ['-I' + src.dir, '--use_fast_math', '--ptxas-options=-v']
self.module = SourceModule(src.kernel, options=cuda_options, no_extern_c=True)