File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -264,11 +264,6 @@ UR_APIEXPORT ur_result_t UR_APICALL urMemGetInfo(ur_mem_handle_t hMemory,
264264
265265 switch (MemInfoType) {
266266 case UR_MEM_INFO_SIZE: {
267- #if HIP_VERSION < 50600000
268- if constexpr (std::is_same_v<T, SurfaceMem>) {
269- return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
270- }
271- #endif
272267 try {
273268 const auto MemVisitor = [](auto &&Mem) -> size_t {
274269 using T = std::decay_t <decltype (Mem)>;
@@ -279,7 +274,7 @@ UR_APIEXPORT ur_result_t UR_APICALL urMemGetInfo(ur_mem_handle_t hMemory,
279274 return AllocSize;
280275 } else if constexpr (std::is_same_v<T, SurfaceMem>) {
281276#if HIP_VERSION < 50600000
282- return 0 ;
277+ throw UR_RESULT_ERROR_UNSUPPORTED_FEATURE ;
283278#else
284279 HIP_ARRAY3D_DESCRIPTOR ArrayDescriptor;
285280 UR_CHECK_ERROR (
You can’t perform that action at this time.
0 commit comments