From 4f8e60801c3d3d2e661d75c20d72493039555a8d Mon Sep 17 00:00:00 2001 From: Megvii Engine Team Date: Thu, 4 Jun 2020 15:21:00 +0800 Subject: [PATCH] feat(dnn): fix Werror by adding macro GitOrigin-RevId: 1f5fe4d46a8e26cde76bb5f251058d5b8ae5e9e2 --- .../matrix_mul/fp32/kernel_general_4x16.h | 16 ++-- .../matrix_mul/fp32/kernel_general_8x12.h | 16 ++-- .../aarch64/matrix_mul/int16/kernel_12x8x1.h | 16 ++-- .../aarch64/matrix_mul/int8/kernel_4x4x16.h | 36 ++++---- .../aarch64/matrix_mul/int8/kernel_8x8x8.h | 88 +++++++++---------- .../matrix_mul/int8/kernel_mk4_4x4x16.h | 8 +- .../matrix_mul/int8x8x16/kernel_4x4x16.h | 36 ++++---- .../matrix_mul/int8x8x16/kernel_8x8x8.h | 88 +++++++++---------- .../aarch64/matrix_mul/quint8/kernel_8x8x8.h | 88 +++++++++---------- .../arm_common/conv_bias/matmul_postprocess.h | 8 +- 10 files changed, 200 insertions(+), 200 deletions(-) diff --git a/dnn/src/aarch64/matrix_mul/fp32/kernel_general_4x16.h b/dnn/src/aarch64/matrix_mul/fp32/kernel_general_4x16.h index fcec5fb96..6ed46ee4a 100644 --- a/dnn/src/aarch64/matrix_mul/fp32/kernel_general_4x16.h +++ b/dnn/src/aarch64/matrix_mul/fp32/kernel_general_4x16.h @@ -459,9 +459,9 @@ void sgemm_4x16_pack_A_n(float * outptr, const float * inptr, int ldin, int y0, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -478,9 +478,9 @@ void sgemm_4x16_pack_A_n(float * outptr, const float * inptr, int ldin, int y0, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -676,9 +676,9 @@ void sgemm_4x16_pack_B_t(float* out, const float* in, int ldin, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -696,9 +696,9 @@ void sgemm_4x16_pack_B_t(float* out, const float* in, int ldin, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/fp32/kernel_general_8x12.h b/dnn/src/aarch64/matrix_mul/fp32/kernel_general_8x12.h index 2ed7787b4..985cbff4b 100644 --- a/dnn/src/aarch64/matrix_mul/fp32/kernel_general_8x12.h +++ b/dnn/src/aarch64/matrix_mul/fp32/kernel_general_8x12.h @@ -964,9 +964,9 @@ void sgemm_8x12_pack_A_n(float* outptr, const float* inptr, int ldin, int y0, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -983,9 +983,9 @@ void sgemm_8x12_pack_A_n(float* outptr, const float* inptr, int ldin, int y0, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1204,9 +1204,9 @@ void sgemm_8x12_pack_B_t(float* out, const float* in, int ldin, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1224,9 +1224,9 @@ void sgemm_8x12_pack_B_t(float* out, const float* in, int ldin, switch ((y + 3) - ymax) { /* Everything falls through in here */ case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int16/kernel_12x8x1.h b/dnn/src/aarch64/matrix_mul/int16/kernel_12x8x1.h index 370af5ecf..cc5d04c1d 100644 --- a/dnn/src/aarch64/matrix_mul/int16/kernel_12x8x1.h +++ b/dnn/src/aarch64/matrix_mul/int16/kernel_12x8x1.h @@ -975,9 +975,9 @@ static void gemm_s16_12x8x1_pack_A_n(int16_t* outptr, const int16_t* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -992,9 +992,9 @@ static void gemm_s16_12x8x1_pack_A_n(int16_t* outptr, const int16_t* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1136,9 +1136,9 @@ static void gemm_s16_12x8x1_transpose_pack_B_n(int16_t* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1153,9 +1153,9 @@ static void gemm_s16_12x8x1_transpose_pack_B_n(int16_t* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int8/kernel_4x4x16.h b/dnn/src/aarch64/matrix_mul/int8/kernel_4x4x16.h index d118a9b27..0503cebce 100644 --- a/dnn/src/aarch64/matrix_mul/int8/kernel_4x4x16.h +++ b/dnn/src/aarch64/matrix_mul/int8/kernel_4x4x16.h @@ -717,9 +717,9 @@ static void gemm_s8_4x4_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -735,9 +735,9 @@ static void gemm_s8_4x4_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -778,19 +778,19 @@ static void gemm_s8_4x4_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (remain >= 0) { switch (remain) { case 7: - inptr0 = zerobuff; + inptr0 = zerobuff; MEGDNN_FALLTHRU case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -809,19 +809,19 @@ static void gemm_s8_4x4_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (remain >= 0) { switch (remain) { case 7: - inptr0 = zerobuff; + inptr0 = zerobuff; MEGDNN_FALLTHRU case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int8/kernel_8x8x8.h b/dnn/src/aarch64/matrix_mul/int8/kernel_8x8x8.h index 6330b115b..ebad760ff 100644 --- a/dnn/src/aarch64/matrix_mul/int8/kernel_8x8x8.h +++ b/dnn/src/aarch64/matrix_mul/int8/kernel_8x8x8.h @@ -992,9 +992,9 @@ static void gemm_s8_8x8_pack_A_n(int8_t* outptr, const int8_t* inptr, int ldin, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1010,9 +1010,9 @@ static void gemm_s8_8x8_pack_A_n(int8_t* outptr, const int8_t* inptr, int ldin, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1064,17 +1064,17 @@ static void gemm_s8_8x8_transpose_pack_A_n(int8_t* out, const int8_t* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1092,17 +1092,17 @@ static void gemm_s8_8x8_transpose_pack_A_n(int8_t* out, const int8_t* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1120,17 +1120,17 @@ static void gemm_s8_8x8_transpose_pack_A_n(int8_t* out, const int8_t* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1187,17 +1187,17 @@ static void gemm_s8_8x8_pack_B_n(int8_t* out, const int8_t* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1216,17 +1216,17 @@ static void gemm_s8_8x8_pack_B_n(int8_t* out, const int8_t* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1245,17 +1245,17 @@ static void gemm_s8_8x8_pack_B_n(int8_t* out, const int8_t* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1332,9 +1332,9 @@ static void gemm_s8_8x8_transpose_pack_B_n(int8_t* outptr, const int8_t* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1351,9 +1351,9 @@ static void gemm_s8_8x8_transpose_pack_B_n(int8_t* outptr, const int8_t* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int8/kernel_mk4_4x4x16.h b/dnn/src/aarch64/matrix_mul/int8/kernel_mk4_4x4x16.h index 6d946c07a..497c0b9e2 100644 --- a/dnn/src/aarch64/matrix_mul/int8/kernel_mk4_4x4x16.h +++ b/dnn/src/aarch64/matrix_mul/int8/kernel_mk4_4x4x16.h @@ -846,9 +846,9 @@ static void gemm_mk4_s8_4x4_pack_B(dt_int8* out, const dt_int8* in, int ldin, if (k + 3 >= ICB) { switch (k + 3 - ICB) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -863,9 +863,9 @@ static void gemm_mk4_s8_4x4_pack_B(dt_int8* out, const dt_int8* in, int ldin, if (k + 3 >= ICB) { switch (k + 3 - ICB) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_4x4x16.h b/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_4x4x16.h index c91daa931..de93bf8b9 100644 --- a/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_4x4x16.h +++ b/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_4x4x16.h @@ -292,9 +292,9 @@ static void gemm_s8x8x16_4x4_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -309,9 +309,9 @@ static void gemm_s8x8x16_4x4_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -362,19 +362,19 @@ static void gemm_s8x8x16_4x4_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (remain >= 0) { switch (remain) { case 7: - inptr0 = zerobuff; + inptr0 = zerobuff; MEGDNN_FALLTHRU case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -393,19 +393,19 @@ static void gemm_s8x8x16_4x4_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (remain >= 0) { switch (remain) { case 7: - inptr0 = zerobuff; + inptr0 = zerobuff; MEGDNN_FALLTHRU case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_8x8x8.h b/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_8x8x8.h index 98f925c14..ae4469447 100644 --- a/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_8x8x8.h +++ b/dnn/src/aarch64/matrix_mul/int8x8x16/kernel_8x8x8.h @@ -918,9 +918,9 @@ static void gemm_s8x8x16_8x8_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -936,9 +936,9 @@ static void gemm_s8x8x16_8x8_pack_A_n(dt_int8* outptr, const dt_int8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -991,17 +991,17 @@ static void gemm_s8x8x16_8x8_transpose_pack_A_n(dt_int8* out, const dt_int8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1019,17 +1019,17 @@ static void gemm_s8x8x16_8x8_transpose_pack_A_n(dt_int8* out, const dt_int8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1047,17 +1047,17 @@ static void gemm_s8x8x16_8x8_transpose_pack_A_n(dt_int8* out, const dt_int8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1113,17 +1113,17 @@ static void gemm_s8x8x16_8x8_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1142,17 +1142,17 @@ static void gemm_s8x8x16_8x8_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1171,17 +1171,17 @@ static void gemm_s8x8x16_8x8_pack_B_n(dt_int8* out, const dt_int8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1259,9 +1259,9 @@ static void gemm_s8x8x16_8x8_transpose_pack_B_n(dt_int8* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1278,9 +1278,9 @@ static void gemm_s8x8x16_8x8_transpose_pack_B_n(dt_int8* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/aarch64/matrix_mul/quint8/kernel_8x8x8.h b/dnn/src/aarch64/matrix_mul/quint8/kernel_8x8x8.h index d1d12a551..9ddc7d07f 100644 --- a/dnn/src/aarch64/matrix_mul/quint8/kernel_8x8x8.h +++ b/dnn/src/aarch64/matrix_mul/quint8/kernel_8x8x8.h @@ -1011,9 +1011,9 @@ static void gemm_u8_8x8_pack_A_n(dt_uint8* outptr, const dt_uint8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1029,9 +1029,9 @@ static void gemm_u8_8x8_pack_A_n(dt_uint8* outptr, const dt_uint8* inptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1084,17 +1084,17 @@ static void gemm_u8_8x8_transpose_pack_A_n(dt_uint8* out, const dt_uint8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1112,17 +1112,17 @@ static void gemm_u8_8x8_transpose_pack_A_n(dt_uint8* out, const dt_uint8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1140,17 +1140,17 @@ static void gemm_u8_8x8_transpose_pack_A_n(dt_uint8* out, const dt_uint8* in, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1208,17 +1208,17 @@ static void gemm_u8_8x8_pack_B_n(dt_uint8* out, const dt_uint8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1237,17 +1237,17 @@ static void gemm_u8_8x8_pack_B_n(dt_uint8* out, const dt_uint8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1266,17 +1266,17 @@ static void gemm_u8_8x8_pack_B_n(dt_uint8* out, const dt_uint8* in, int ldin, if (k + 7 >= kmax) { switch (k + 7 - kmax) { case 6: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 5: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 4: - inptr3 = zerobuff; + inptr3 = zerobuff; MEGDNN_FALLTHRU case 3: - inptr4 = zerobuff; + inptr4 = zerobuff; MEGDNN_FALLTHRU case 2: - inptr5 = zerobuff; + inptr5 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr6 = zerobuff; + inptr6 = zerobuff; MEGDNN_FALLTHRU case 0: inptr7 = zerobuff; break; @@ -1354,9 +1354,9 @@ static void gemm_u8_8x8_transpose_pack_B_n(dt_uint8* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; @@ -1373,9 +1373,9 @@ static void gemm_u8_8x8_transpose_pack_B_n(dt_uint8* outptr, if (y + 3 >= ymax) { switch (y + 3 - ymax) { case 2: - inptr1 = zerobuff; + inptr1 = zerobuff; MEGDNN_FALLTHRU case 1: - inptr2 = zerobuff; + inptr2 = zerobuff; MEGDNN_FALLTHRU case 0: inptr3 = zerobuff; break; diff --git a/dnn/src/arm_common/conv_bias/matmul_postprocess.h b/dnn/src/arm_common/conv_bias/matmul_postprocess.h index a4f0e6571..d15c03b96 100644 --- a/dnn/src/arm_common/conv_bias/matmul_postprocess.h +++ b/dnn/src/arm_common/conv_bias/matmul_postprocess.h @@ -27,9 +27,9 @@ namespace arm_common { vreinterpret_s32_s8(vres), idx / 4); \ break; \ case 3: \ - vst1_lane_s8(C + 2, vres, idx + 2); \ + vst1_lane_s8(C + 2, vres, idx + 2); MEGDNN_FALLTHRU\ case 2: \ - vst1_lane_s8(C + 1, vres, idx + 1); \ + vst1_lane_s8(C + 1, vres, idx + 1); MEGDNN_FALLTHRU\ case 1: \ vst1_lane_s8(C + 0, vres, idx + 0); \ break; \ @@ -44,9 +44,9 @@ namespace arm_common { vreinterpret_s32_u8(vres), idx / 4); \ break; \ case 3: \ - vst1_lane_u8(C + 2, vres, idx + 2); \ + vst1_lane_u8(C + 2, vres, idx + 2); MEGDNN_FALLTHRU\ case 2: \ - vst1_lane_u8(C + 1, vres, idx + 1); \ + vst1_lane_u8(C + 1, vres, idx + 1); MEGDNN_FALLTHRU\ case 1: \ vst1_lane_u8(C + 0, vres, idx + 0); \ break; \ -- GitLab