aboutsummaryrefslogtreecommitdiff
path: root/src/core/deviceinterface.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/deviceinterface.h')
-rw-r--r--src/core/deviceinterface.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/core/deviceinterface.h b/src/core/deviceinterface.h
index 2db5577..e15994e 100644
--- a/src/core/deviceinterface.h
+++ b/src/core/deviceinterface.h
@@ -37,12 +37,20 @@
#include <CL/cl.h>
#include <string>
#include "object.h"
+#include "icd.h"
/* This pulls in legacy::PassManager when LLVM >= 3.4 */
#include <llvm/PassManager.h>
namespace Coal
{
+class DeviceInterface;
+}
+
+struct _cl_device_id: public Coal::descriptor<Coal::DeviceInterface, _cl_device_id> {};
+
+namespace Coal
+{
class DeviceBuffer;
class DeviceProgram;
@@ -53,13 +61,14 @@ class Event;
class Program;
class Kernel;
+
/**
* \brief Abstraction layer between core Clover objects and the devices
*
* This interface is used by the core Clover classes to communicate with the
* devices, that must reimplement all the functions described here.
*/
-class DeviceInterface : public Object
+class DeviceInterface : public _cl_device_id, public Object
{
public:
DeviceInterface() : Object(Object::T_Device, 0) {}
@@ -365,7 +374,4 @@ class DeviceKernel
}
-struct _cl_device_id : public Coal::DeviceInterface
-{};
-
#endif