aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc
diff options
context:
space:
mode:
authorGravatar Benjamin Kramer <kramerb@google.com>2018-10-01 19:42:12 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2018-10-01 19:46:29 -0700
commit991f06fd50fc73285ce415d57f720994c2b2e861 (patch)
tree0b87402386aad22ec958f171bfd57f9c7c3e8571 /tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc
parentbeede8525be5386451bf0098992c37416d1864db (diff)
[XLA] Migrate from gtl::FlatSet to absl::flat_hash_set
PiperOrigin-RevId: 215324035
Diffstat (limited to 'tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc')
-rw-r--r--tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc b/tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc
index 2590473c77..9795b2830b 100644
--- a/tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc
+++ b/tensorflow/compiler/xla/service/while_loop_invariant_code_motion.cc
@@ -16,17 +16,17 @@ limitations under the License.
#include "tensorflow/compiler/xla/service/while_loop_invariant_code_motion.h"
#include "absl/algorithm/container.h"
#include "absl/container/flat_hash_map.h"
+#include "absl/container/flat_hash_set.h"
#include "absl/container/inlined_vector.h"
#include "tensorflow/compiler/xla/service/tuple_util.h"
#include "tensorflow/compiler/xla/service/while_util.h"
#include "tensorflow/compiler/xla/util.h"
-#include "tensorflow/core/lib/gtl/flatset.h"
namespace xla {
using absl::flat_hash_map;
+using absl::flat_hash_set;
using absl::InlinedVector;
-using tensorflow::gtl::FlatSet;
// Copies `to_hoist` to the computation containing `while_instr`, hoisting its
// operands as needed. All of its transitive operands are expected to be either
@@ -35,7 +35,7 @@ using tensorflow::gtl::FlatSet;
// them into `hoisted_instructions`.
static void CreateLoopInvariantCopy(
flat_hash_map<HloInstruction*, HloInstruction*>* hoisted_instructions,
- FlatSet<HloInstruction*>* unhoisted_invariant_instructions,
+ flat_hash_set<HloInstruction*>* unhoisted_invariant_instructions,
HloInstruction* while_instr, HloInstruction* to_hoist) {
HloComputation* parent_of_while = while_instr->parent();
HloComputation* while_body = while_instr->while_body();
@@ -153,7 +153,7 @@ WhileLoopInvariantCodeMotion::TryHoistingInvariantInstructionsFromWhileBody(
// unprofitable to be hoisted alone by NotWorthHoistingIndividually. When we
// hoist an instruction in this set, we move it from
// unhoisted_invariant_instructions to hoisted_instructions.
- FlatSet<HloInstruction*> unhoisted_invariant_instructions;
+ flat_hash_set<HloInstruction*> unhoisted_invariant_instructions;
// Invariant GTE's axiomatically satisfy the constraints for
// unhoisted_invariant_instructions -- they can be legally hoisted, but there