diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2018-09-06 20:48:11 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-09-06 20:52:28 -0700 |
commit | 44efcf0db7b9204a77710a7f076c904d0e13e6fa (patch) | |
tree | 2114672b05239fcdb9554bcf26354a81b4f8565b /tensorflow/compiler/xla/service/hlo_instruction.h | |
parent | a7e3047fea74a43174c063320fd0cb6bb6dcceb1 (diff) |
Split out HloDomainInstruction as subclass form HloInstruction.
PiperOrigin-RevId: 211916428
Diffstat (limited to 'tensorflow/compiler/xla/service/hlo_instruction.h')
-rw-r--r-- | tensorflow/compiler/xla/service/hlo_instruction.h | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/tensorflow/compiler/xla/service/hlo_instruction.h b/tensorflow/compiler/xla/service/hlo_instruction.h index de60ddf42d..1619d1a985 100644 --- a/tensorflow/compiler/xla/service/hlo_instruction.h +++ b/tensorflow/compiler/xla/service/hlo_instruction.h @@ -1079,15 +1079,6 @@ class HloInstruction { return other->has_sharding() ? sharding() == other->sharding() : false; } - // Retrieves the operand side metadata of a kDomain instruction. - const DomainMetadata& operand_side_metadata() const { - return *operand_side_metadata_; - } - // Retrieves the user side metadata of a kDomain instruction. - const DomainMetadata& user_side_metadata() const { - return *user_side_metadata_; - } - // When creating a new instruction which either replaces, or shifts up (kCopy // insertion case), another instruction, we need to make sure the certain // properties of the new instruction are copied into the derived one. As of @@ -1496,6 +1487,12 @@ class HloInstruction { // Delegates to HloDotInstruction::dot_dimension_numbers(). const DotDimensionNumbers& dot_dimension_numbers() const; + // Delegates to HloDomainInstruction::operand_side_metadata(). + const DomainMetadata& operand_side_metadata() const; + + // Delegates to HloDomainInstruction::user_side_metadata(). + const DomainMetadata& user_side_metadata() const; + // Old methods kept for smooth subclassing transition END. protected: @@ -1641,10 +1638,6 @@ class HloInstruction { // many element tuples. std::shared_ptr<const HloSharding> sharding_; - // Fields used by the kDomain instruction. - std::unique_ptr<DomainMetadata> operand_side_metadata_; - std::unique_ptr<DomainMetadata> user_side_metadata_; - // Computations called by this instruction. std::vector<HloComputation*> called_computations_; |