RFR: 8260191: Do not include access.hpp in oop.hpp

Ioi Lam iklam at openjdk.java.net
Wed Jan 20 22:58:03 UTC 2021


Please review this trivial change.

oop.h is included by 860 out of 1000 HotSpot .o files. It includes access.h for this member function declaration only:

template <DecoratorSet decorator> oop obj_field_access(int offset) const;

Instead of access.h, oop.h should include accessDecorators.hpp. This avoids including lots of header files from the Access API.

HotSpot build time is reduced by about 0.5% for this single-line change.

Tested with mach5: tier1, builds-tier2, builds-tier3, builds-tier4 and builds-tier5. Also locally: aarch64, arm, ppc64, s390, x86, and zero.

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

Commit messages:
 - 8260191: Do not include access.hpp in oop.hpp

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

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


More information about the hotspot-dev mailing list