Add integrated device property

This commit is contained in:
Rahul Garg
2018-06-02 13:11:16 +05:30
orang tua df450c6680
melakukan 1a02bc364f
5 mengubah file dengan 16 tambahan dan 0 penghapusan
+2
Melihat File
@@ -114,6 +114,7 @@ typedef struct hipDeviceProp_t {
int isMultiGpuBoard; ///< 1 if device is on a multi-GPU board, 0 if not.
int canMapHostMemory; ///< Check whether HIP can map host memory
int gcnArch; ///< AMD GCN Arch Value. Eg: 803, 701
int integrated; ///< APU vs dGPU
} hipDeviceProp_t;
@@ -289,6 +290,7 @@ typedef enum hipDeviceAttribute_t {
hipDeviceAttributeMaxSharedMemoryPerMultiprocessor, ///< Maximum Shared Memory Per
///< Multiprocessor.
hipDeviceAttributeIsMultiGpuBoard, ///< Multiple GPU devices.
hipDeviceAttributeIntegrated, ///< iGPU
} hipDeviceAttribute_t;
@@ -809,6 +809,9 @@ inline static hipError_t hipDeviceGetAttribute(int* pi, hipDeviceAttribute_t att
case hipDeviceAttributeIsMultiGpuBoard:
cdattr = cudaDevAttrIsMultiGpuBoard;
break;
case hipDeviceAttributeIntegrated:
cdattr = cudaDevAttrIntegrated;
break;
default:
cerror = cudaErrorInvalidValue;
break;