RFR: 8305203: Simplify trimming operation in Region::Ideal [v2]

Xin Liu xliu at openjdk.org
Mon Apr 3 19:42:42 UTC 2023


> This patch improves how Region::Ideal trims unreachable paths. 
> 
> 1. Don't restart from beginning. Trimming doesn't change the DU-chain.
> 2. Replace DFIterator with DFIterator_Fast. The later is a raw pointer in release build.
> 3. Don't call add_users_to_worklist(this) repeatly.
> 4. Reduce its strength from add_users_to_worklist to
>    add_users_to_worklist0 because RegionNode has no special logic.
> 
> This patch also includes a cosmetic change: rename n to 'use' inside of the loop.
> Otherwise, we would overshadow Node* n = in(i). Nothing wrong but harder to read.

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

  Update coding style according to reviewer's feedback.

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/13238/files
  - new: https://git.openjdk.org/jdk/pull/13238/files/40510a42..8732ee71

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

  Stats: 2 lines in 1 file changed: 0 ins; 0 del; 2 mod
  Patch: https://git.openjdk.org/jdk/pull/13238.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13238/head:pull/13238

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


More information about the hotspot-compiler-dev mailing list