Added feature for cross-compilation and seperated hcc api from hip api

[ROCm/hip commit: 1dcdfc93f1]
This commit is contained in:
Aditya Atluri
2016-04-06 14:18:51 -05:00
parent 5f1f0b34d0
commit cf9cefcb6a
5 changed files with 37 additions and 17 deletions
+8
View File
@@ -0,0 +1,8 @@
#ifndef HCC_H
#define HCC_H
#if defined(__HIP_PLATFORM_HCC__) && !defined (__HIP_PLATFORM_NVCC__)
#include <hcc_detail/hcc_acc.h>
#endif
#endif
+20
View File
@@ -0,0 +1,20 @@
#ifndef HCC_ACC_H
#define HCC_ACC_H
#include "hip_runtime_api.h"
#if __cplusplus
#ifdef __HCC__
#include <hc.hpp>
/**
* @brief Return hc::accelerator associated with the specified deviceId
*/
hipError_t hipHccGetAccelerator(int deviceId, hc::accelerator *acc);
/**
* @brief Return hc::accelerator_view associated with the specified stream
*/
hipError_t hipHccGetAcceleratorView(hipStream_t stream, hc::accelerator_view **av);
#endif
#endif
#endif
@@ -1041,20 +1041,6 @@ hipError_t hipDriverGetVersion(int *driverVersion) ;
* @endcode
*
*/
#if __cplusplus
#ifdef __HCC__
#include <hc.hpp>
/**
* @brief Return hc::accelerator associated with the specified deviceId
*/
hipError_t hipHccGetAccelerator(int deviceId, hc::accelerator *acc);
/**
* @brief Return hc::accelerator_view associated with the specified stream
*/
hipError_t hipHccGetAcceleratorView(hipStream_t stream, hc::accelerator_view **av);
#endif
#endif
// end-group HCC_Specific
/**