diff --git a/CMakeLists.txt b/CMakeLists.txt index 593c8bc03..21eb9a9d5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,7 +24,8 @@ project(clr) ########## # Defaults ########## -if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") +if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC" + OR CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC") add_compile_options("/wd4267" "/wd4244" "/wd4996") string(REPLACE "/GR" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS}) string(REPLACE "/W3" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS}) @@ -32,6 +33,12 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") add_compile_options(/MTd) add_compile_options(-D_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH) endif() + + if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") + # Unlike when targeting MSFT's MSVC, when targeting clang-cl, + # CMake does not add these automatically. Add them ourselves. + add_compile_options("/DWIN32" "/D_WINDOWS" "/EHsc") + endif() endif() if (AMD_COMPUTE_WIN) diff --git a/hipamd/src/hip_table_interface.cpp b/hipamd/src/hip_table_interface.cpp index 5e86b86ed..94f273ebf 100644 --- a/hipamd/src/hip_table_interface.cpp +++ b/hipamd/src/hip_table_interface.cpp @@ -244,6 +244,11 @@ hipError_t hipDeviceGetStreamPriorityRange(int* leastPriority, int* greatestPrio return hip::GetHipDispatchTable()->hipDeviceGetStreamPriorityRange_fn(leastPriority, greatestPriority); } +hipError_t hipDeviceGetTexture1DLinearMaxWidth(size_t* maxWidthInElements, + const hipChannelFormatDesc* fmtDesc, int device) { + return hip::GetHipDispatchTable()->hipDeviceGetTexture1DLinearMaxWidth_fn(maxWidthInElements, + fmtDesc, device); +} hipError_t hipDeviceGetUuid(hipUUID* uuid, hipDevice_t device) { return hip::GetHipDispatchTable()->hipDeviceGetUuid_fn(uuid, device); } @@ -483,6 +488,50 @@ hipError_t hipGraphAddEventRecordNode(hipGraphNode_t* pGraphNode, hipGraph_t gra return hip::GetHipDispatchTable()->hipGraphAddEventRecordNode_fn(pGraphNode, graph, pDependencies, numDependencies, event); } +hipError_t hipGraphAddExternalSemaphoresSignalNode( + hipGraphNode_t* pGraphNode, hipGraph_t graph, const hipGraphNode_t* pDependencies, + size_t numDependencies, const hipExternalSemaphoreSignalNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphAddExternalSemaphoresSignalNode_fn( + pGraphNode, graph, pDependencies, numDependencies, nodeParams); +} +hipError_t hipGraphAddExternalSemaphoresWaitNode( + hipGraphNode_t* pGraphNode, hipGraph_t graph, const hipGraphNode_t* pDependencies, + size_t numDependencies, const hipExternalSemaphoreWaitNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphAddExternalSemaphoresWaitNode_fn( + pGraphNode, graph, pDependencies, numDependencies, nodeParams); +} +hipError_t hipGraphExternalSemaphoresSignalNodeSetParams( + hipGraphNode_t hNode, const hipExternalSemaphoreSignalNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphExternalSemaphoresSignalNodeSetParams_fn(hNode, + nodeParams); +} +hipError_t hipGraphExternalSemaphoresSignalNodeGetParams( + hipGraphNode_t hNode, hipExternalSemaphoreSignalNodeParams* params_out) { + return hip::GetHipDispatchTable()->hipGraphExternalSemaphoresSignalNodeGetParams_fn(hNode, + params_out); +} +hipError_t hipGraphExternalSemaphoresWaitNodeGetParams( + hipGraphNode_t hNode, hipExternalSemaphoreWaitNodeParams* params_out) { + return hip::GetHipDispatchTable()->hipGraphExternalSemaphoresWaitNodeGetParams_fn(hNode, + params_out); +} +hipError_t hipGraphExternalSemaphoresWaitNodeSetParams( + hipGraphNode_t hNode, const hipExternalSemaphoreWaitNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphExternalSemaphoresWaitNodeSetParams_fn(hNode, + nodeParams); +} +hipError_t hipGraphExecExternalSemaphoresSignalNodeSetParams( + hipGraphExec_t hGraphExec, hipGraphNode_t hNode, + const hipExternalSemaphoreSignalNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphExecExternalSemaphoresSignalNodeSetParams_fn( + hGraphExec, hNode, nodeParams); +} +hipError_t hipGraphExecExternalSemaphoresWaitNodeSetParams( + hipGraphExec_t hGraphExec, hipGraphNode_t hNode, + const hipExternalSemaphoreWaitNodeParams* nodeParams) { + return hip::GetHipDispatchTable()->hipGraphExecExternalSemaphoresWaitNodeSetParams_fn( + hGraphExec, hNode, nodeParams); +} hipError_t hipGraphAddEventWaitNode(hipGraphNode_t* pGraphNode, hipGraph_t graph, const hipGraphNode_t* pDependencies, size_t numDependencies, hipEvent_t event) { @@ -1880,9 +1929,9 @@ hipError_t hipDrvLaunchKernelEx(const HIP_LAUNCH_CONFIG* config, hipFunction_t f return hip::GetHipDispatchTable()->hipDrvLaunchKernelEx_fn(config, f, kernel, extra); } -hipError_t hipMemGetHandleForAddressRange(void* handle, hipDeviceptr_t dptr, size_t size, +hipError_t hipMemGetHandleForAddressRange(void* handle, hipDeviceptr_t dptr, size_t size, hipMemRangeHandleType handleType, unsigned long long flags) { return hip::GetHipDispatchTable()->hipMemGetHandleForAddressRange_fn(handle, dptr, size, handleType, flags); -} \ No newline at end of file +}