@@ -167,7 +167,12 @@ DebugOptions DefaultDebugOptionsIgnoringFlags() {
opts.set_xla_cpu_matmul_tiling_k_dim(8);
opts.set_xla_cpu_enable_mlir_fusion_outlining(true);
opts.set_xla_cpu_enable_experimental_deallocation(true);
+#ifdef ENABLE_ANNC
+ opts.set_xla_cpu_enable_xnnpack(false);
+ // Kernel Selector
+ opts.set_xla_cpu_use_kernel_selector(false);
+#endif
opts.set_xla_partitioning_algorithm(
DebugOptions::PARTITIONING_ALGORITHM_NOOP);
@@ -1104,6 +1109,18 @@ void MakeDebugOptionsFlags(std::vector<tsl::Flag>* flag_list,
&DebugOptions::set_xla_gpu_enable_latency_hiding_scheduler),
debug_options->xla_gpu_enable_latency_hiding_scheduler(),
"Enable latency-hiding scheduler for XLA:GPU"));
+#ifdef ENABLE_ANNC
+ flag_list->push_back(tsl::Flag(
+ "xla_cpu_enable_xnnpack",
+ bool_setter_for(&DebugOptions::set_xla_cpu_enable_xnnpack),
+ debug_options->xla_cpu_enable_xnnpack(),
+ "Enable XNNPACK ops rewriter."));
+ flag_list->push_back(
+ tsl::Flag("xla_cpu_use_kernel_selector",
+ bool_setter_for(&DebugOptions::set_xla_cpu_use_kernel_selector),
+ debug_options->xla_cpu_use_kernel_selector(),
+ "Replace dot with custom call to libraries."));
+#endif
flag_list->push_back(tsl::Flag(
"xla_gpu_enable_analytical_latency_estimator",
bool_setter_for(