Skip to content

Commit

Permalink
Revert "Reland cadence quantized_linear_per_tensor_out cpu 1eb924f^..f…
Browse files Browse the repository at this point in the history
…d33294" (pytorch#7225)

Revert "Reland cadence quantized_linear_per_tensor_out cpu 1eb924f^..fd33294 …"

Caused merge conflict issue in diff train.

This reverts commit 78b60df.
  • Loading branch information
zonglinpeng authored Dec 7, 2024
1 parent 538bfaf commit 4c43c86
Show file tree
Hide file tree
Showing 9 changed files with 100 additions and 926 deletions.
4 changes: 1 addition & 3 deletions backends/cadence/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ include(${EXECUTORCH_ROOT}/build/Utils.cmake)

# Let files say "include <executorch/path/to/header.h>".
set(_common_include_directories ${EXECUTORCH_ROOT}/..)
set(TARGET_DIR reference)

if(EXECUTORCH_CADENCE_CPU_RUNNER)
include(${EXECUTORCH_ROOT}/build/Codegen.cmake)
Expand Down Expand Up @@ -60,9 +61,6 @@ if(EXECUTORCH_CADENCE_CPU_RUNNER)
${_common_include_directories}
)

set(TARGET_DIR reference)
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/${TARGET_DIR}/kernels)

target_link_libraries(
cadence_runner
executorch
Expand Down
50 changes: 0 additions & 50 deletions backends/cadence/aot/functions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -142,41 +142,6 @@
- arg_meta: null
kernel_name: torch::executor::where_out

- op: transpose_copy.int_out
kernels:
- arg_meta: null
kernel_name: torch::executor::transpose_copy_int_out

- op: eq.Scalar_out
kernels:
- arg_meta: null
kernel_name: torch::executor::eq_scalar_out

- op: logical_not.out
kernels:
- arg_meta: null
kernel_name: torch::executor::logical_not_out

- op: any.out
kernels:
- arg_meta: null
kernel_name: torch::executor::any_out

- op: native_group_norm.out
kernels:
- arg_meta: null
kernel_name: torch::executor::native_group_norm_out

- op: sum.IntList_out
kernels:
- arg_meta: null
kernel_name: torch::executor::sum_dim_out

- op: select_copy.int_out
kernels:
- arg_meta: null
kernel_name: torch::executor::select_copy_int_out

# custom ops
- func: cadence::quantize_per_tensor.out(Tensor input, float scale, int zero_point, int quant_min, int quant_max, ScalarType dtype, *, Tensor(a!) out) -> Tensor(a!)
variants: function
Expand Down Expand Up @@ -218,18 +183,3 @@
kernels:
- arg_meta: null
kernel_name: impl::reference::quantized_matmul_out

- func: cadence::quantized_linear.per_tensor_out(Tensor src, Tensor weight, Tensor bias, SymInt src_zero_point, SymInt weight_zero_point, SymInt out_multiplier, SymInt out_shift, SymInt out_zero_point, Tensor? offset, *, Tensor(a!) out) -> Tensor(a!)
kernels:
- arg_meta: null
kernel_name: impl::reference::quantized_linear_per_tensor_out

- func: cadence::im2row.out(Tensor input, int[2] kernel_size, int[2] dilation, int[2] padding, int[2] stride, Tensor in_zero_point, bool channel_last=False, *, Tensor(a!) out) -> Tensor(a!)
kernels:
- arg_meta: null
kernel_name: impl::reference::im2row_out

- func: cadence::quantized_conv.per_tensor_out(Tensor input, Tensor weight, Tensor bias, int[] stride, SymInt[] padding, int[] dilation, int groups, int input_zero_point, int weight_zero_point, float bias_scale, float out_scale, int out_zero_point, int out_multiplier, int out_shift, bool channel_last=False, *, Tensor(a!) out) -> Tensor(a!)
kernels:
- arg_meta: null
kernel_name: impl::reference::quantized_conv_per_tensor_out
11 changes: 0 additions & 11 deletions backends/cadence/reference/operators/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,6 @@ set(_aten_ops__srcs
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_expand_copy.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_gelu.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_empty.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_transpose_copy.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_eq.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_logical_not.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_any.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_native_group_norm.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_sum.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/op_select_copy.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/util/dtype_util.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/util/normalization_ops_util.cpp"
"${EXECUTORCH_ROOT}/kernels/portable/cpu/util/select_copy_util.cpp"
)
add_library(aten_ops_cadence ${_aten_ops__srcs})
target_link_libraries(aten_ops_cadence PUBLIC executorch)
Expand All @@ -88,7 +78,6 @@ add_library(
"quantize_per_tensor.cpp"
"dequantize_per_tensor.cpp"
"quantized_matmul_out.cpp"
"im2row_out.cpp"
)
target_include_directories(
custom_ops PUBLIC ${ROOT_DIR}/.. ${CMAKE_BINARY_DIR}
Expand Down
206 changes: 0 additions & 206 deletions backends/cadence/reference/operators/im2row_out.cpp

This file was deleted.

57 changes: 0 additions & 57 deletions backends/cadence/reference/operators/operators.h

This file was deleted.

Loading

0 comments on commit 4c43c86

Please sign in to comment.