tsan: add a useful debug check

llvm-svn: 214082
This commit is contained in:
Dmitry Vyukov 2014-07-28 13:54:18 +00:00
parent 595683da00
commit 3baf5b390d
1 changed files with 1 additions and 0 deletions

View File

@ -65,6 +65,7 @@ class DenseSlabAlloc {
}
void Free(Cache *c, IndexT idx) {
DCHECK_NE(idx, 0);
if (c->pos == Cache::kSize)
Drain(c);
c->cache[c->pos++] = idx;