diff --git a/doc/runtime.rst b/doc/runtime.rst index f24c41b840c839549a10f8a73fed08a14f26cb71..bf639e26aaa2a0d1c7ad8bb6fe0f5ef69fbc2f91 100644 --- a/doc/runtime.rst +++ b/doc/runtime.rst @@ -145,6 +145,24 @@ Platforms, Devices and Contexts :func:`create_some_context`. See, e.g. this `explanation by AMD <http://developer.amd.com/support/KnowledgeBase/Lists/KnowledgeBase/DispForm.aspx?ID=71>`_. + .. note:: + + Because of how OpenCL changed in order to support Installable Client + Drivers (ICDs) in OpenCL 1.1, the following will *look* reasonable + but often actually not work:: + + import pyopencl as cl + ctx = cl.Context(dev_type=cl.device_type.ALL) + + Instead, make sure to choose a platform when choosing a device by type:: + + import pyopencl as cl + + platforms = cl.get_platforms() + ctx = cl.Context( + dev_type=cl.device_type.ALL, + properties=[(cl.context_properties.PLATFORM, platforms[0])]) + .. note:: For