diff options
author | 2018-09-11 10:41:44 -0700 | |
---|---|---|
committer | 2018-09-11 10:51:01 -0700 | |
commit | 36e1a5ea5ba2dd5eaa7f4cfc84a61f8ce3ea20e1 (patch) | |
tree | 4f1671f78f5971b02dc2af66f57eabbf01005112 /tensorflow/core/common_runtime/copy_tensor.cc | |
parent | 36d7b12357df667dcd427c070e21779ed83f4ec9 (diff) |
[TF] Variant improvements.
1. Change Variant Decode to accept VariantTensorData (non-ref).
This should allow some optimization in the future.
In the meantime it means removing the variant.h include from tensor.h, since
variant_encode_decode.h now relies on tensor.h and variant.h now relies on that.
It also means we found a bunch of places where tensor.proto.h, variant.h, and
mutex.h were being imported through tensor.h (along with a bunch of other crap);
so now we directly import them in order to compile.
2. Move Variant registry to use TypeIndex instead of a TypeName string; this should
speed up registry lookups.
PiperOrigin-RevId: 212478896
Diffstat (limited to 'tensorflow/core/common_runtime/copy_tensor.cc')
-rw-r--r-- | tensorflow/core/common_runtime/copy_tensor.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tensorflow/core/common_runtime/copy_tensor.cc b/tensorflow/core/common_runtime/copy_tensor.cc index f8cb854b52..cf3d1f0b79 100644 --- a/tensorflow/core/common_runtime/copy_tensor.cc +++ b/tensorflow/core/common_runtime/copy_tensor.cc @@ -358,7 +358,7 @@ static Status WrappedTensorDeviceCopy( #define REGISTER_WRAPPED_TENSOR_COPY(DIRECTION) \ INTERNAL_REGISTER_UNARY_VARIANT_DEVICE_COPY_FUNCTION( \ - Tensor, DIRECTION, "tensorflow::Tensor", WrappedTensorDeviceCopy) + Tensor, DIRECTION, WrappedTensorDeviceCopy) REGISTER_WRAPPED_TENSOR_COPY(VariantDeviceCopyDirection::HOST_TO_DEVICE); REGISTER_WRAPPED_TENSOR_COPY(VariantDeviceCopyDirection::DEVICE_TO_HOST); |