Skip to content

Commit 5171251

Browse files
Arm backend: Remove obsolete QDQ fusion CLI flags (pytorch#22824)
Remove --enable_qdq_fusion_pass and the corresponding run.sh option. The flag has had no effect since its deprecation in ExecuTorch 1.2. Signed-off-by: Sebastian Larsson <sebastian.larsson@arm.com>
1 parent 1498f7a commit 5171251

2 files changed

Lines changed: 1 addition & 21 deletions

File tree

‎backends/arm/scripts/aot_arm_compiler.py‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -702,11 +702,6 @@ def _get_args():
702702
action="store_false",
703703
help="Disable strict checking while exporting models.",
704704
)
705-
parser.add_argument(
706-
"--enable_qdq_fusion_pass",
707-
action="store_true",
708-
help="[DEPRECATED] This flag is no longer used and will be removed in a future release.",
709-
)
710705
parser.add_argument(
711706
"--enable_debug_mode",
712707
required=False,
@@ -1043,13 +1038,6 @@ def main() -> None: # noqa: C901
10431038

10441039
model = exported_program.module()
10451040

1046-
if args.enable_qdq_fusion_pass:
1047-
logging.warning(
1048-
"--enable_qdq_fusion_pass is deprecated and has no effect. "
1049-
"Quantized node replacement is now handled within the "
1050-
"respective compilation paths."
1051-
)
1052-
10531041
model_name = os.path.basename(os.path.splitext(args.model_name)[0])
10541042
if args.intermediates:
10551043
os.makedirs(args.intermediates, exist_ok=True)

‎examples/arm/run.sh‎

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ scratch_dir_set=false
4545
toolchain="arm-none-eabi-gcc"
4646
select_ops_list="aten::_softmax.out"
4747
select_ops_list_overridden=false
48-
qdq_fusion_op=false
4948
model_explorer=false
5049
perf_overlay=false
5150
visualize_tosa=false
@@ -88,7 +87,6 @@ function help() {
8887
echo " --specify_ethosu_scratch Use actual Ethos-U scratch size for given model to size temp allocator"
8988
echo " --et_build_root=<FOLDER> Executorch build output root folder to use, defaults to ${et_build_root}"
9089
echo " --scratch-dir=<FOLDER> Path to your Ethos-U scratch dir if you not using default ${arm_scratch_dir}"
91-
echo " --qdq_fusion_op Enable QDQ fusion op"
9290
echo " --model_explorer Enable model explorer to visualize a TOSA or PTE model graph."
9391
echo " --visualize_pte With --model_explorer, visualize PTE flatbuffer model and delegates. Cannot be used with --visualize_tosa"
9492
echo " NOTE: If PTE contains an Ethos-U delegate, the Ethos-U subgraph will be visualized if aot_arm_compiler_flags includes -i for TOSA dumps."
@@ -125,7 +123,6 @@ for arg in "$@"; do
125123
--specify_ethosu_scratch) specify_ethosu_scratch=true ;;
126124
--et_build_root=*) et_build_root="${arg#*=}";;
127125
--scratch-dir=*) arm_scratch_dir="${arg#*=}" ; scratch_dir_set=true ;;
128-
--qdq_fusion_op) qdq_fusion_op=true;;
129126
--model_explorer) model_explorer=true ;;
130127
--perf_overlay) perf_overlay=true ;;
131128
--visualize_tosa) visualize_tosa=true ;;
@@ -618,7 +615,6 @@ cd "${et_root_dir}"
618615

619616
bundleio_flag=""
620617
etrecord_flag_template=""
621-
qdq_fusion_op_flag=""
622618
if [ "$build_with_etdump" = true ] ; then
623619
etrecord_flag_template="--etrecord"
624620
fi
@@ -627,10 +623,6 @@ if [ "$bundleio" = true ] ; then
627623
bundleio_flag="--bundleio"
628624
fi
629625

630-
if [ "$qdq_fusion_op" = true ] ; then
631-
qdq_fusion_op_flag="--enable_qdq_fusion_pass"
632-
fi
633-
634626
if [[ "${auto_configure}" == true ]]; then
635627
set_default_build_dir_path
636628
else
@@ -756,7 +748,7 @@ for i in "${!test_model[@]}"; do
756748
fi
757749

758750
model_etrecord_flag="${etrecord_flag_template}"
759-
ARM_AOT_CMD="python3 -m backends.arm.scripts.aot_arm_compiler --model_name=${model} --target=${target} ${model_compiler_flags} --intermediate=${output_folder} --output=${pte_file} --system_config=${system_config} --memory_mode=${memory_mode} $bundleio_flag ${model_etrecord_flag} --config=${config} $qdq_fusion_op_flag"
751+
ARM_AOT_CMD="python3 -m backends.arm.scripts.aot_arm_compiler --model_name=${model} --target=${target} ${model_compiler_flags} --intermediate=${output_folder} --output=${pte_file} --system_config=${system_config} --memory_mode=${memory_mode} $bundleio_flag ${model_etrecord_flag} --config=${config}"
760752
echo "CALL ${ARM_AOT_CMD}" >&2
761753
${ARM_AOT_CMD} 1>&2
762754

0 commit comments

Comments
 (0)