Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8285645

Consolidating Hashtable cleanup

XMLWordPrintable

      BasicHashtble's destructor only frees hashtable buckets, but not entries in the hashtable, that results a lot of duplicated code of its subclasses to cleanup hashtable entries.

      The duplicated code can be consolidated into the base class.

      There is a discussion here: https://github.com/openjdk/jdk/pull/8148#issuecomment-1092088844

      Also, there is no point to complicate Entry allocation: first allocate memory, then invoke placement new.

            Unassigned Unassigned
            zgu Zhengyu Gu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: