diff options
Diffstat (limited to 'tensorflow/compiler/jit/mark_for_compilation_pass.cc')
-rw-r--r-- | tensorflow/compiler/jit/mark_for_compilation_pass.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tensorflow/compiler/jit/mark_for_compilation_pass.cc b/tensorflow/compiler/jit/mark_for_compilation_pass.cc index 7eab7bb28f..77b45aa11e 100644 --- a/tensorflow/compiler/jit/mark_for_compilation_pass.cc +++ b/tensorflow/compiler/jit/mark_for_compilation_pass.cc @@ -257,6 +257,11 @@ Status MarkForCompilationPass::Run( ®istration)) { return false; } + + // Don't compile control trigger nodes. We won't preserve their deadness + // semantics correctly, so it's safest not to compile them. + if (node->IsControlTrigger()) return false; + // If this device requires a JIT, we must say yes. if (registration->requires_compilation) return true; |