MIOpen icon indicating copy to clipboard operation
MIOpen copied to clipboard

Compiling failure XdlopsBackwardData for fp16

Open zjing14 opened this issue 5 years ago • 6 comments

./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 16, 7, 7 --weights 4, 16, 1, 1 --pads_strides_dilations 0 0 1 1 1 1 --trans_output_pads 0 0
./gridwise_convolution_backward_data_implicit_gemm_v1r1_xdlops_gnchw_gkcyx_gnkhw.hpp:68:9: error: static_assert failed due to requirement 'K % 8 == 0' "K needs to be in multiple of KPACK"
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 16, 14, 14 --weights 4, 16, 3, 3 --pads_strides_dilations 1 1 2 2 1 1 --trans_output_pads 0 0
./gridwise_convolution_backward_data_implicit_gemm_v1r1_xdlops_gnchw_gkcyx_gnkhw.hpp:68:9: error: static_assert failed due to requirement 'K % 8 == 0' "K needs to be in multiple of KPACK"
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 16, 7, 7 --weights 8, 16, 1, 1 --pads_strides_dilations 0 0 1 1 1 1 --trans_output_pads 0 0
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 16, 14, 14 --weights 8, 16, 3, 3 --pads_strides_dilations 1 1 2 2 1 1 --trans_output_pads 0 0
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 32, 7, 7 --weights 4, 32, 1, 1 --pads_strides_dilations 0 0 1 1 1 1 --trans_output_pads 0 0
./gridwise_convolution_backward_data_implicit_gemm_v1r1_xdlops_gnchw_gkcyx_gnkhw.hpp:68:9: error: static_assert failed due to requirement 'K % 8 == 0' "K needs to be in multiple of KPACK"
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 32, 14, 14 --weights 4, 32, 3, 3 --pads_strides_dilations 1 1 2 2 1 1 --trans_output_pads 0 0
./gridwise_convolution_backward_data_implicit_gemm_v1r1_xdlops_gnchw_gkcyx_gnkhw.hpp:68:9: error: static_assert failed due to requirement 'K % 8 == 0' "K needs to be in multiple of KPACK"
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 32, 7, 7 --weights 8, 32, 1, 1 --pads_strides_dilations 0 0 1 1 1 1 --trans_output_pads 0 0
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"
./bin/test_conv2d --half --cmode conv --pmode default --group-count 1 --disable-backward-weights --input 16, 32, 7, 7 --weights 8, 32, 1, 1 --pads_strides_dilations 0 0 1 1 1 1 --trans_output_pads 0 0
./gridwise_gemm_xdlops_fp16_bfp16.hpp:797:9: error: static_assert failed due to requirement 'M % 256 == 0 && N % 256 == 0 && K % 8 == 0' "wrong! cannot divide work evenly among block"

zjing14 avatar Sep 01 '20 17:09 zjing14

we should deprecate this solver/kernel, because we would use following instead: ConvHipImplicitGemmBwdDataV1R1Xdlops gridwise_convolution_backward_data_implicit_gemm_v1r1_xdlops_nchw_kcyx_nkhw.cpp

asroy avatar Sep 03 '20 21:09 asroy

Good news. Just in case -- if we need to quickly disable it, then changing the default value of respective env variable will do the job ( IsDisabled() -> !IsEnabled()).

atamazov avatar Sep 03 '20 22:09 atamazov

@zjing14 and @asroy, what is the status of this issue?

aserio avatar Sep 22 '20 16:09 aserio

@zjing14 please close if new PR resolves this issue

aserio avatar Oct 06 '20 16:10 aserio

Workaround by #457. Full blown fix is not yet implemented, so let's keep it open (until W/A is removed) but lower priority. And this is not a bug anymore.

atamazov avatar Oct 06 '20 20:10 atamazov

@zjing14 Is this still an issue? If not, can we close this ticket? Thanks!

ppanchad-amd avatar Mar 17 '24 01:03 ppanchad-amd

Hi @atamazov, is it OK to close the issue? As we are not observing the failure in the original test: "failed due to requirement 'K % 8 == 0' "K needs to be in multiple of KPACK""

huanrwan-amd avatar Dec 02 '24 19:12 huanrwan-amd