From 6ea8286d14a5e042bb9311f4d1e1412d1d499e29 Mon Sep 17 00:00:00 2001 From: Michael LIAO Date: Tue, 3 Mar 2020 16:36:37 -0500 Subject: [PATCH] Fix `-Werror=switch`. Change-Id: Ib0850a3f79308efeeecd18bb03ecd82bd355ef85 [ROCm/clr commit: d2d0225c2eca09f6c9ae58e0a586e34a558b8503] --- projects/clr/hipamd/vdi/hip_conversions.hpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/projects/clr/hipamd/vdi/hip_conversions.hpp b/projects/clr/hipamd/vdi/hip_conversions.hpp index de3cbaad0a..abaa4d1949 100644 --- a/projects/clr/hipamd/vdi/hip_conversions.hpp +++ b/projects/clr/hipamd/vdi/hip_conversions.hpp @@ -186,6 +186,8 @@ cl_mem_object_type getCLMemObjectType(const hipResourceType hipResType) { return CL_MEM_OBJECT_IMAGE1D; case hipResourceTypePitch2D: return CL_MEM_OBJECT_IMAGE2D; + default: + break; } ShouldNotReachHere(); @@ -330,6 +332,8 @@ hipArray_Format getArrayFormat(const hipChannelFormatDesc& desc) { case 32: return HIP_AD_FORMAT_FLOAT; } + default: + break; } ShouldNotReachHere(); @@ -364,6 +368,8 @@ int getNumChannels(const hipResourceViewFormat hipFormat) { case hipResViewFormatHalf4: case hipResViewFormatFloat4: return 4; + default: + break; } ShouldNotReachHere(); @@ -406,6 +412,8 @@ hipArray_Format getArrayFormat(const hipResourceViewFormat hipFormat) { case hipResViewFormatFloat2: case hipResViewFormatFloat4: return HIP_AD_FORMAT_FLOAT; + default: + break; } ShouldNotReachHere(); @@ -500,6 +508,8 @@ hipResourceViewFormat getResourceViewFormat(const hipChannelFormatDesc& desc) { return hipResViewFormatFloat4; } } + default: + break; } ShouldNotReachHere(); @@ -636,4 +646,4 @@ _HIP_MEMCPY3D getMemcpy3DParms(const hip_Memcpy2D& desc2D) { return desc3D; } -}; \ No newline at end of file +};