RFR: 8336297: C2: Fix -Wzero-as-null-pointer-constant warnings in derived Node ctors

Kim Barrett kbarrett at openjdk.org
Fri Jul 12 20:29:16 UTC 2024


Please review this change that removes some -Wzero-as-null-pointer-constant
warnings (when enabled) in C2 code. The constructors for some classes derived
from Node pass 0 as the first argument to the base class constructor. Since
that parameter is a Node*, this triggers a warning.  Changing to pass nullptr
removes the warning.

Testing: mach5 tier1

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

Commit messages:
 - fix C2 derived node ctors

Changes: https://git.openjdk.org/jdk/pull/20162/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=20162&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8336297
  Stats: 18 lines in 5 files changed: 0 ins; 0 del; 18 mod
  Patch: https://git.openjdk.org/jdk/pull/20162.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/20162/head:pull/20162

PR: https://git.openjdk.org/jdk/pull/20162


More information about the hotspot-compiler-dev mailing list