Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 11:05:44

0001 #ifndef HeterogeneousCore_CUDAServices_interface_CUDAInterface
0002 #define HeterogeneousCore_CUDAServices_interface_CUDAInterface
0003 
0004 #include <utility>
0005 
0006 class CUDAInterface {
0007 public:
0008   CUDAInterface() = default;
0009   virtual ~CUDAInterface() = default;
0010 
0011   virtual bool enabled() const = 0;
0012 
0013   virtual int numberOfDevices() const = 0;
0014 
0015   // Returns the (major, minor) CUDA compute capability of the given device.
0016   virtual std::pair<int, int> computeCapability(int device) const = 0;
0017 };
0018 
0019 #endif  // HeterogeneousCore_CUDAServices_interface_CUDAInterface