RFR: 8263834: Work around gdb <incomplete type> for HashtableEntry

Ioi Lam iklam at openjdk.java.net
Fri Mar 19 06:28:55 UTC 2021


Please review this one liner to work around a gdb bug in printing subtypes of `HashtableEntry`:

(gdb) p this
$1 = (const PlaceholderEntry * const) 0x7ffff0242a30
(gdb) p *this
$2 = <incomplete type>
(gdb) ptype this
type = const class PlaceholderEntry {
    <incomplete type>
} * const

The fix is to no longer subclass `HashtableEntry` from `CHeapObj`. Apparently that makes gdb happy. None of our code requires this subclass relationship.

Tested with tiers 1-4.

-------------

Commit messages:
 - 8263834: Work around gdb <incomplete type> for HashtableEntry

Changes: https://git.openjdk.java.net/jdk/pull/3084/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=3084&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8263834
  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.java.net/jdk/pull/3084.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/3084/head:pull/3084

PR: https://git.openjdk.java.net/jdk/pull/3084


More information about the hotspot-dev mailing list