From e5c5e048a0b0d401007206aa1c1488406a834c54 Mon Sep 17 00:00:00 2001 From: Derek Murray Date: Wed, 31 Jul 2019 15:29:18 -0700 Subject: [PATCH] Remove unused field InspectingPlacer::graph_. This causes a warning when building with -Wunused-private-field. PiperOrigin-RevId: 261010830 --- tensorflow/core/common_runtime/colocation_graph.cc | 2 +- tensorflow/core/common_runtime/inspecting_placer.cc | 6 ++---- tensorflow/core/common_runtime/inspecting_placer.h | 3 +-- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/tensorflow/core/common_runtime/colocation_graph.cc b/tensorflow/core/common_runtime/colocation_graph.cc index ac54b8539ee..4f706800900 100644 --- a/tensorflow/core/common_runtime/colocation_graph.cc +++ b/tensorflow/core/common_runtime/colocation_graph.cc @@ -539,7 +539,7 @@ ColocationGraph::ColocationGraph(const Graph* graph, const FunctionStack& stack, : graph_(*graph), stack_(stack), flib_def_(*flib_def), - inspecting_placer_(graph, stack, flib_def, device_set, default_device, + inspecting_placer_(stack, flib_def, device_set, default_device, allow_soft_placement, log_device_placement), inspection_required_checker_(graph, flib_def), device_set_(*device_set), diff --git a/tensorflow/core/common_runtime/inspecting_placer.cc b/tensorflow/core/common_runtime/inspecting_placer.cc index 19cc784ec54..88317bfc5c2 100644 --- a/tensorflow/core/common_runtime/inspecting_placer.cc +++ b/tensorflow/core/common_runtime/inspecting_placer.cc @@ -108,15 +108,13 @@ class ColocationGraphToIOColocationGroups { int next_group_id_; }; -InspectingPlacer::InspectingPlacer(const Graph* graph, - const FunctionStack& stack, +InspectingPlacer::InspectingPlacer(const FunctionStack& stack, const FunctionLibraryDefinition* flib_def, const DeviceSet* device_set, const Device* default_device, bool allow_soft_placement, bool log_device_placement) - : graph_(*graph), - stack_(stack), + : stack_(stack), flib_def_(*flib_def), device_set_(*device_set), default_device_(default_device), diff --git a/tensorflow/core/common_runtime/inspecting_placer.h b/tensorflow/core/common_runtime/inspecting_placer.h index 6cba3649cb9..3fe6a1a9188 100644 --- a/tensorflow/core/common_runtime/inspecting_placer.h +++ b/tensorflow/core/common_runtime/inspecting_placer.h @@ -69,7 +69,7 @@ class InspectingPlacer { // TODO(iga): Add a "stack trace" to detect recursion and improve log // messages. Currently, we will enter an infinite loop for recursive // functions. - InspectingPlacer(const Graph* graph, const FunctionStack& stack, + InspectingPlacer(const FunctionStack& stack, const FunctionLibraryDefinition* flib_def, const DeviceSet* device_set, const Device* default_device, bool allow_soft_placement, bool log_device_placement); @@ -80,7 +80,6 @@ class InspectingPlacer { IOColocationGroups* groups); private: - const Graph& graph_; const FunctionStack stack_; const FunctionLibraryDefinition& flib_def_; const DeviceSet& device_set_;