RFR: 8283699: Improve the peephole mechanism of hotspot [v4]

Quan Anh Mai qamai at openjdk.org
Fri Oct 7 15:08:11 UTC 2022


On Thu, 6 Oct 2022 21:31:40 GMT, Dean Long <dlong at openjdk.org> wrote:

>> While it seems to be a little boiler-plate, I think a general helper that removes, inserts an arbitrary number of nodes, and connects the graph correctly is hard to write. What do you think? Thanks a lot.
>
> How does it work when there is no peepprocedure?  I would expect that all the boiler-plate details are taken care of by peepreplace.

The code produced by `peepreplace` is really limited, it cannot be applied in this case because both the `MachSpillCopy` and `MachProj` are not match rules. Also, I think a generated code is more powerful than a helper function, so achieving something general with a helper function would be hard. I think we can refactor it into a helper if there are similarities arise later instead. What do you think?

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

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


More information about the hotspot-compiler-dev mailing list