Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #48082 from njeffrie:f1_depthwise
PiperOrigin-RevId: 365150386 Change-Id: I0cca1c34d2e600cea51ef45b37e5cf808891541a
- Loading branch information
Showing
2 changed files
with
54 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
tensorflow/lite/micro/tools/make/ext_libs/xtensa_patch.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
diff --git a/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise.c b/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise.c | ||
index 3e29856..e550ebf 100644 | ||
--- a/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise.c | ||
+++ b/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise.c | ||
@@ -249,7 +249,6 @@ WORD32 xa_nn_conv2d_depthwise_getsize | ||
XA_NNLIB_CHK_COND((kernel_height <= 0), -1); | ||
XA_NNLIB_CHK_COND((kernel_width <= 0), -1); | ||
XA_NNLIB_CHK_COND((channels_multiplier <= 0), -1); | ||
- XA_NNLIB_CHK_COND((x_stride <= 0 || x_stride > kernel_width), -1); | ||
XA_NNLIB_CHK_COND((y_stride <= 0 || y_stride > kernel_height), -1); | ||
XA_NNLIB_CHK_COND((x_padding < 0), -1); | ||
XA_NNLIB_CHK_COND((y_padding < 0), -1); | ||
diff --git a/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise_sym8sxasym8s.c b/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise_sym8sxasym8s.c | ||
index e719da1..5b7390f 100644 | ||
--- a/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise_sym8sxasym8s.c | ||
+++ b/algo/kernels/cnn/hifi4/xa_nn_conv2d_depthwise_sym8sxasym8s.c | ||
@@ -659,7 +659,6 @@ WORD32 xa_nn_conv2d_depthwise_per_chan_sym8sxasym8s | ||
XA_NNLIB_ARG_CHK_COND((input_channels <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((kernel_height <= 0 || kernel_width <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((kernel_height > input_height), -1); | ||
- XA_NNLIB_ARG_CHK_COND((kernel_width > input_width), -1); | ||
XA_NNLIB_ARG_CHK_COND((channels_multiplier <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((y_stride <= 0 || x_stride <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((y_padding < 0 || x_padding < 0), -1); | ||
@@ -671,8 +670,6 @@ WORD32 xa_nn_conv2d_depthwise_per_chan_sym8sxasym8s | ||
XA_NNLIB_ARG_CHK_COND((inp_data_format != 0 && inp_data_format != 1), -1); | ||
XA_NNLIB_ARG_CHK_COND((out_data_format != 0), -1); | ||
/* Implementation dependent checks */ | ||
- XA_NNLIB_ARG_CHK_COND((y_stride > kernel_height), -1); | ||
- XA_NNLIB_ARG_CHK_COND((x_stride > kernel_width), -1); | ||
|
||
if(inp_data_format == 0) | ||
{ | ||
diff --git a/algo/kernels/cnn/hifi4/xa_nn_conv2d_std_sym8sxasym8s.c b/algo/kernels/cnn/hifi4/xa_nn_conv2d_std_sym8sxasym8s.c | ||
index b16b9fc..38e69d3 100644 | ||
--- a/algo/kernels/cnn/hifi4/xa_nn_conv2d_std_sym8sxasym8s.c | ||
+++ b/algo/kernels/cnn/hifi4/xa_nn_conv2d_std_sym8sxasym8s.c | ||
@@ -198,7 +198,6 @@ WORD32 xa_nn_conv2d_std_per_chan_sym8sxasym8s( | ||
XA_NNLIB_ARG_CHK_COND((input_channels <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((kernel_height <= 0 || kernel_width <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((kernel_height > input_height), -1); | ||
- XA_NNLIB_ARG_CHK_COND((kernel_width > input_width), -1); | ||
XA_NNLIB_ARG_CHK_COND((out_channels <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((y_stride <= 0 || x_stride <= 0), -1); | ||
XA_NNLIB_ARG_CHK_COND((y_padding < 0 || x_padding < 0), -1); |