diff options
author | Yunxing Dai <yunxing@google.com> | 2018-08-21 17:08:12 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-08-21 17:12:22 -0700 |
commit | 3cb3a450ed845c4602080f43d7bb6cfade298a22 (patch) | |
tree | 21e5a40fcb72737bd2cb00829bd049c5173d20e0 /tensorflow/compiler/xla/service/hlo_instructions.cc | |
parent | 95d718a8a41370f31ccb3b32aaac7fd00b0291e4 (diff) |
[XLA] gtl::optional->absl::optional
PiperOrigin-RevId: 209686671
Diffstat (limited to 'tensorflow/compiler/xla/service/hlo_instructions.cc')
-rw-r--r-- | tensorflow/compiler/xla/service/hlo_instructions.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/tensorflow/compiler/xla/service/hlo_instructions.cc b/tensorflow/compiler/xla/service/hlo_instructions.cc index e91cabbb72..dbafa35b2a 100644 --- a/tensorflow/compiler/xla/service/hlo_instructions.cc +++ b/tensorflow/compiler/xla/service/hlo_instructions.cc @@ -301,8 +301,7 @@ HloAllReduceInstruction::HloAllReduceInstruction( const Shape& shape, tensorflow::gtl::ArraySlice<HloInstruction*> operands, HloComputation* reduce_computation, tensorflow::gtl::ArraySlice<int64> replica_group_ids, - tensorflow::StringPiece barrier, - const tensorflow::gtl::optional<int64>& all_reduce_id) + tensorflow::StringPiece barrier, const absl::optional<int64>& all_reduce_id) : HloInstruction(HloOpcode::kCrossReplicaSum, shape), replica_group_ids_(replica_group_ids.begin(), replica_group_ids.end()), cross_replica_sum_barrier_(barrier.begin(), barrier.end()), @@ -702,7 +701,7 @@ HloInstructionProto HloMapInstruction::ToProto() const { } bool HloMapInstruction::IsElementwiseImpl( - const tensorflow::gtl::optional<int64>& operand_idx) const { + const absl::optional<int64>& operand_idx) const { if (!dimensions().empty()) { // Check that the map is executed in elementwise compatible dimensions. if (dimensions().size() != shape().dimensions_size()) { @@ -815,7 +814,7 @@ HloInstructionProto HloConstantInstruction::ToProto() const { } bool HloConstantInstruction::IsElementwiseImpl( - const tensorflow::gtl::optional<int64>& operand_idx) const { + const absl::optional<int64>& operand_idx) const { return true; } @@ -955,7 +954,7 @@ HloInstructionProto HloFusionInstruction::ToProto() const { } bool HloFusionInstruction::IsElementwiseImpl( - const tensorflow::gtl::optional<int64>& operand_idx) const { + const absl::optional<int64>& operand_idx) const { if (!operand_idx.has_value()) { for (auto* fused : fused_instructions()) { if (fused->opcode() != HloOpcode::kParameter && !fused->IsElementwise()) { @@ -1387,7 +1386,7 @@ std::vector<string> HloRngInstruction::ExtraAttributesToStringImpl( } bool HloRngInstruction::IsElementwiseImpl( - const tensorflow::gtl::optional<int64>& operand_idx) const { + const absl::optional<int64>& operand_idx) const { return true; } |