RFR: 8311125: Remove unused parameter 'phase' in AllocateNode::Ideal_allocation [v2]

Xin Liu xliu at openjdk.org
Fri Jun 30 19:43:06 UTC 2023


> There are 2 overloaded AllocateNode::Idea_allocation() in graphkit.cpp.
> One of them never uses 'phase' in the pattern-matching effort.
> 
> C++ compiler may emit a warning for the unused parameter. We will need to take care of it if we treat 
> warning as error. It also unnecessarily couple CheckCastPP with PhaseValue. In some places, we have to
> gain the instance for it. 
> 
> I would like to remove 'phase' as parameter. This is a pure clean-up. The other Idea_allocation() does 
> use PhaseValue* phase to get constant nodes, so leave it alone.

Xin Liu has updated the pull request incrementally with one additional commit since the last revision:

  Clean up useless 'phase' parameter more.

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/14719/files
  - new: https://git.openjdk.org/jdk/pull/14719/files/1b9dd182..8afbde7c

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=14719&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=14719&range=00-01

  Stats: 8 lines in 3 files changed: 0 ins; 0 del; 8 mod
  Patch: https://git.openjdk.org/jdk/pull/14719.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/14719/head:pull/14719

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


More information about the hotspot-compiler-dev mailing list