void removeEmptyStacks() {
    myDocumentStacks.entrySet().removeIf(each -> each.getValue().isEmpty());
    // make sure the following entrySet iteration will not go over empty buckets.
    CollectionFactory.trimMap(myDocumentStacks);

    cleanWeaklyTrackedEmptyStacks(myDocumentsWithStacks);
    cleanWeaklyTrackedEmptyStacks(myNonlocalVirtualFilesWithStacks);
  }
void removeEmptyStacks()