Skip to content

Commit bf4969f

Browse files
Weiming Zhaotianboh
Weiming Zhao
authored andcommitted
fix for wrong simplify_preprocess option
(cherry picked from commit ff18c1f)
1 parent fc97a57 commit bf4969f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

include/halo/halo.h

+1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ struct CXXCodeGenOpts {
7575
bool enable_ipu_device = false;
7676
bool use_ipu_model = false;
7777
bool separate_constants = false;
78+
bool simplify_for_preprocess = false;
7879
bool disable_broadcasting = true;
7980
bool enable_type_cast = false;
8081
bool remove_input_transpose = false;

include/halo/utils/passes_helper.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ static void PopulateOptPasses(PassManager* pm, const std::string& target,
148148
pm->AddInputRewriterPass(inputs);
149149
}
150150
pm->AddInstSimplifyPass(
151-
target.substr(0, 3) == "cxx", opts.disable_broadcasting,
151+
opts.simplify_for_preprocess, opts.disable_broadcasting,
152152
opts.remove_input_transpose, opts.remove_output_transpose,
153153
opts.disable_conv_bn, fusion_opts.ConvBias);
154154
if (opts.channel_order != ChannelOrder::None) {

0 commit comments

Comments
 (0)