Merge pull request #39898 from rangjiaheng:bugfix/hash_table_lock_excluded

PiperOrigin-RevId: 317115206
Change-Id: Ie99abf49c6b712f463fb0fe2e11fa7f4c6fd7f7b
This commit is contained in:
TensorFlower Gardener 2020-06-18 09:17:57 -07:00
commit dcc9479bba

View File

@ -557,7 +557,7 @@ class MutableDenseHashTable final : public LookupInterface {
TensorShape value_shape() const override { return value_shape_; }
int64 MemoryUsed() const override {
int64 MemoryUsed() const override TF_LOCKS_EXCLUDED(mu_) {
tf_shared_lock l(mu_);
return sizeof(MutableDenseHashTable) + key_buckets_.AllocatedBytes() +
value_buckets_.AllocatedBytes() + empty_key_.AllocatedBytes();