Skip to content

Commit 13dcd7c

Browse files
CRobeckmeta-codesync[bot]
authored andcommitted
add experimental env for disabling llvm slpvectorization
Summary: Add an experimental flag to disable slpvectorization for helion testing Reviewed By: agron911 Differential Revision: D89382448 fbshipit-source-id: bf5f5f09e13bcbd6cf757ad4c000d1f1026c9d93
1 parent 13f6272 commit 13dcd7c

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

include/triton/Tools/Sys/GetEnv.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ inline const std::set<std::string> CACHE_INVALIDATING_ENV_VARS = {
3030
"MLIR_DISABLE_MULTITHREADING",
3131
"TRITON_DEFAULT_FP_FUSION",
3232
"TRITON_DISABLE_LINE_INFO",
33+
"TRITON_DISABLE_SLPVECTORIZATION",
3334
"TRITON_ENABLE_LLVM_DEBUG",
3435
"TRITON_HIP_GLOBAL_PREFETCH",
3536
"TRITON_HIP_LOCAL_PREFETCH",

python/src/llvm.cc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,13 @@ void init_triton_llvm(py::module &&m) {
354354
// regressions with some scheduling solution.
355355
tuningOptions.SLPVectorization = true;
356356

357+
bool disableSLPVectorization =
358+
mlir::triton::tools::getBoolEnv("TRITON_DISABLE_SLPVECTORIZATION");
359+
360+
if (disableSLPVectorization) {
361+
tuningOptions.SLPVectorization = false;
362+
}
363+
357364
std::string pluginFile =
358365
mlir::triton::tools::getStrEnv("LLVM_PASS_PLUGIN_PATH");
359366

0 commit comments

Comments
 (0)