I'm getting confused. :-)

Let's use a counterexample again:

```java
List<ByteBuf> bufs = ...;
for (int i = 0; i < 1048576; i ++) {
  bufs.add(ctx.alloc().buffer());
}
...
for (ByteBuf b: bufs) {
  buf.release();
}
```

Once the code above runs, the size of the cache will become 1048576.  `allocations` also will become 1048576.  At this point, calling `freeUpIfNecessary()` will not do anything but resetting `allocations` to 0, because `allocations` isn't less than `size()`.

Now, let's assume you allocated only a couple buffers and then released them during the next 10 seconds.  After then, `freeUpIfNecessary()` will free only a couple memory regions, because it will free only as many memory regions as `allocations` (= 2).  At this pace, you will need apx. 1048576 / 2 * 10 seconds to clean up the thread-local cache to satisfactory level.

Am I missing something again?  What I'm trying to tell is that `allocations` isn't the right value to determine the number of regions to release.