Added kernel compilation driver apis

1. Added 2 new driver apis, hipModuleLoad, hipModuleGetFunction

Change-Id: If464a7fad178121e3da791c7ac9e17ebc01a9cd0
Issues: When a sample written with them shows Aborted (core dumped) when exiting
Αυτή η υποβολή περιλαμβάνεται σε:
Aditya Atluri
2016-08-16 14:36:25 -05:00
γονέας 7015675983
υποβολή 3d27bbd3db
5 αρχεία άλλαξαν με 98 προσθήκες και 7 διαγραφές
@@ -77,7 +77,6 @@ class ihipStream_t;
class ihipDevice_t;
class ihipCtx_t;
// Color defs for debug messages:
#define KNRM "\x1B[0m"
#define KRED "\x1B[31m"
@@ -397,8 +396,6 @@ public:
typedef ihipStreamCriticalBase_t<StreamMutex> ihipStreamCritical_t;
typedef LockedAccessor<ihipStreamCritical_t> LockedAccessor_StreamCrit_t;
// Internal stream structure.
class ihipStream_t {
public:
@@ -660,8 +657,6 @@ extern void ihipSetTs(hipEvent_t e);
hipStream_t ihipSyncAndResolveStream(hipStream_t);
// Stream printf functions:
inline std::ostream& operator<<(std::ostream& os, const ihipStream_t& s)
{
@@ -51,6 +51,11 @@ typedef struct ihipCtx_t *hipCtx_t;
typedef struct ihipDevice_t *hipDevice_t;
typedef struct ihipStream_t *hipStream_t;
typedef uint64_t hipFunction;
typedef uint64_t hipModule;
typedef struct hipEvent_t {
struct ihipEvent_t *_handle;
} hipEvent_t;
@@ -1085,6 +1090,21 @@ hipError_t hipDeviceGetFromId(hipDevice_t *device, int deviceId);
hipError_t hipDriverGetVersion(int *driverVersion) ;
hipError_t hipModuleLoad(hipModule *module, const char *fname);
hipError_t hipModuleGetFunction(hipFunction *function, hipModule module, const char *kname);
hipError_t hipDrvLaunchKernel(hipFunction f,
unsigned int gridDimX,
unsigned int gridDimY,
unsigned int gridDimZ,
unsigned int blockDimX,
unsigned int blockDimY,
unsigned int blockDimZ,
unsigned int sharedMemBytes,
hipStream_t stream,
void **kernelParams,
void **extra) __attribute__((deprecated("kernelParams is not fully supported, use extra instead"))) ;
// doxygen end Version Management
/**