From 9c75b7ffd22ead5842dcb47e7b037f3bea46b9a7 Mon Sep 17 00:00:00 2001 From: "A. Unique TensorFlower" Date: Mon, 24 Jun 2019 10:12:46 -0700 Subject: [PATCH] Remove unused variables. PiperOrigin-RevId: 254781764 --- tensorflow/c/python_api.cc | 1 - .../compiler/jit/mark_for_compilation_pass_test.cc | 13 ------------- 2 files changed, 14 deletions(-) diff --git a/tensorflow/c/python_api.cc b/tensorflow/c/python_api.cc index 2c9d9f3a15b..3bdaa866ee6 100644 --- a/tensorflow/c/python_api.cc +++ b/tensorflow/c/python_api.cc @@ -43,7 +43,6 @@ void SetAttr(TF_Graph* graph, TF_Operation* op, const char* attr_name, void ClearAttr(TF_Graph* graph, TF_Operation* op, const char* attr_name, TF_Status* status) { - AttrValue attr_val; mutex_lock l(graph->mu); op->node.ClearAttr(attr_name); diff --git a/tensorflow/compiler/jit/mark_for_compilation_pass_test.cc b/tensorflow/compiler/jit/mark_for_compilation_pass_test.cc index bebff82abda..f06e1f52dcb 100644 --- a/tensorflow/compiler/jit/mark_for_compilation_pass_test.cc +++ b/tensorflow/compiler/jit/mark_for_compilation_pass_test.cc @@ -88,7 +88,6 @@ absl::flat_hash_map> GetClusterSets( TEST(XlaCompilationTest, Chains) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = @@ -114,7 +113,6 @@ TEST(XlaCompilationTest, Chains) { TEST(XlaCompilationTest, UncompilableCycles) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -135,7 +133,6 @@ TEST(XlaCompilationTest, UncompilableCycles) { TEST(XlaCompilationTest, CompilableCycles) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -157,7 +154,6 @@ TEST(XlaCompilationTest, CompilableCycles) { TEST(XlaCompilationTest, StringUnsupported) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp( @@ -177,7 +173,6 @@ TEST(XlaCompilationTest, StringUnsupported) { TEST(XlaCompilationTest, HalfSupported) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Tensor t(DT_HALF, TensorShape()); @@ -253,7 +248,6 @@ TEST(XlaCompilationTest, FunctionCalls) { FunctionLibraryDefinition flib_def(OpRegistry::Global(), flib); std::unique_ptr graph(new Graph(&flib_def)); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately, &flib_def); Node* a = @@ -291,7 +285,6 @@ TEST(XlaCompilationTest, CallXlaDeviceFuncWithResourceOp) { FunctionLibraryDefinition flib_def(OpRegistry::Global(), flib); std::unique_ptr graph(new Graph(&flib_def)); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately, &flib_def); Node* resource = @@ -381,7 +374,6 @@ REGISTER_OP_GRADIENT("Unsupported", UnsupportedGrad); TEST(XlaCompilationTest, SymbolicGradients) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = @@ -449,7 +441,6 @@ TEST(XlaCompilationTest, Loops) { TEST(XlaCompilationTest, CyclesWithAllDifferentScopesGlobalJitOverridden) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -483,7 +474,6 @@ TEST(XlaCompilationTest, CyclesWithAllDifferentScopesGlobalJitOverridden) { TEST(XlaCompilationTest, CyclesWithAllDifferentScopes) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -512,7 +502,6 @@ TEST(XlaCompilationTest, CyclesWithAllDifferentScopes) { TEST(XlaCompilationTest, CyclesWithSplittingScopes) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -555,7 +544,6 @@ TEST(XlaCompilationTest, CyclesWithSplittingScopes) { TEST(XlaCompilationTest, CyclesWithDifferentScopesAndBridge) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts() @@ -789,7 +777,6 @@ TEST(XlaCompilationTest, IllegalCycle_UsefulErrorMessage) { TEST(XlaCompilationTest, Retval) { std::unique_ptr graph(new Graph(OpRegistry::Global())); - GraphDef graphdef; { GraphDefBuilder builder(GraphDefBuilder::kFailImmediately); Node* a = ops::SourceOp("Const", builder.opts()