Skip to content

Commit

Permalink
Add an option to disable aten::cat in TE (re-revert) (#50101)
Browse files Browse the repository at this point in the history
Summary:
This reverts commit ace78dd.

Fixes #{issue number}

Pull Request resolved: #50101

Reviewed By: eellison

Differential Revision: D25784785

Pulled By: Krovatkin

fbshipit-source-id: cbb3d377e03303f6c8c71f4c59c6d90ab40d55f7
  • Loading branch information
Krovatkin authored and facebook-github-bot committed Jan 5, 2021
1 parent bbae677 commit 3cd2f1f
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions torch/csrc/jit/passes/tensorexpr_fuser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
#include <torch/csrc/jit/tensorexpr/kernel.h>
#include <torch/csrc/utils/memory.h>

// NOLINTNEXTLINE
C10_DEFINE_bool(
torch_jit_disable_cat,
false,
"disable aten::cat in TE fusion groups");
namespace torch {
namespace jit {

Expand Down Expand Up @@ -202,6 +207,10 @@ bool isSupported(Node* node) {
}
}

if (FLAGS_torch_jit_disable_cat && node->kind() == aten::cat) {
return false;
}

return true;
}

Expand Down

0 comments on commit 3cd2f1f

Please sign in to comment.