Revision effd9dd1e1eaadb6109dde0eb6dabc07c8ac2fec authored by Andres Noetzli on 29 August 2015, 01:06:32 UTC, committed by Andres Noetzli on 29 August 2015, 01:06:32 UTC
Summary:
MarkLogsSynced() was doing `logs_.erase(it++);`. The standard is saying:

```
all iterators and references are invalidated, unless the erased members are at an end (front or back) of the deque (in which case only iterators and references to the erased members are invalidated)
```

Because `it` is an iterator to the first element of the container, it is
invalidated, only one iteration is executed and `log.getting_synced = false;`
is not being done, so `while (logs_.front().getting_synced)` in `WriteImpl()`
is not terminating.

Test Plan: make db_bench && ./db_bench --benchmarks=fillsync

Reviewers: igor, rven, IslamAbdelRahman, anthony, kradhakrishnan, yhchiang, sdong, tnovak

Reviewed By: tnovak

Subscribers: kolmike, dhruba, leveldb

Differential Revision: https://reviews.facebook.net/D45807
1 parent 72a9b73
Raw File
.gitignore
TARGETS
make_config.mk

*.a
*.arc
*.d
*.dylib*
*.gcda
*.gcno
*.o
*.so
*.so.*
*_test
*_bench
*_stress
*.out
*.class
*.jar
*.*jnilib*
*.d-e
*.o-*
*.swp
*~
*.vcxproj
*.vcxproj.filters
*.sln
*.cmake
CMakeCache.txt
CMakeFiles/
build/

ldb
manifest_dump
sst_dump
util/build_version.cc
build_tools/VALGRIND_LOGS/
coverage/COVERAGE_REPORT
.gdbhistory
package/
.phutil_module_cache
unity
tags
rocksdb_dump
rocksdb_undump

java/out
java/target
java/test-libs
java/*.log
java/include/org_rocksdb_*.h

.idea/
*.iml

unity.cc
java/crossbuild/.vagrant
.vagrant/
java/**.asc
java/javadoc

scan_build_report/
t
LOG
back to top