aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/stream_executor/event.h
diff options
context:
space:
mode:
authorGravatar A. Unique TensorFlower <gardener@tensorflow.org>2018-07-09 01:49:04 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2018-07-09 01:54:33 -0700
commit955e356e4c69d3fce4ac2bac5966671e964f9627 (patch)
tree95183ec6d5122e5dae704b8a80796f01dfa1b85a /tensorflow/stream_executor/event.h
parentcaf711b6be448d46354e0cbef23989fa837efcf7 (diff)
[SE,XLA] Switch to using multiple streams in xla_device_context
Instead of having one stream for compute, host-to-device and device-to-host transfers, switch to having separate streams, just like the GPU does. Add a se::Event field to XlaTensor to allow accurate inter-stream dependencies to be created. As part of this: - Fix TransferManager::TransferLiteralFrom/ToDevice to correctly make generated substreams wait on their master stream. - Fix Stream::BlockHostUntilDone() to not block on or return substreams. This behavior is completely broken and not only nondeterministically returns substreams to the pool but causes indefinite hangs with the HostStream. PiperOrigin-RevId: 203726543
Diffstat (limited to 'tensorflow/stream_executor/event.h')
-rw-r--r--tensorflow/stream_executor/event.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/tensorflow/stream_executor/event.h b/tensorflow/stream_executor/event.h
index 1f37262c78..9cc87a7c12 100644
--- a/tensorflow/stream_executor/event.h
+++ b/tensorflow/stream_executor/event.h
@@ -61,6 +61,9 @@ class Event {
// Returns a pointer to the underlying platform-specific implementation.
internal::EventInterface* implementation() { return implementation_.get(); }
+ Event(Event&&) = default;
+ Event& operator=(Event&&) = default;
+
private:
friend class Stream;