RFR: JDK-8308994: C2: Re-implement experimental post loop vectorization
Emanuel Peter
epeter at openjdk.org
Fri Jun 23 10:55:07 UTC 2023
On Wed, 21 Jun 2023 08:24:19 GMT, Pengfei Li <pli at openjdk.org> wrote:
> ## TL;DR
>
> This patch completely re-implements C2's experimental post loop vectorization for better stability, maintainability and performance. Compared with the original implementation, this new implementation adds a standalone loop phase in C2's ideal loop phases and can vectorize more post loops. The original implementation and all code related to multi-versioned post loops are deleted in this patch. More details about this patch can be found in the document replied in this pull request.
src/hotspot/share/opto/loopnode.hpp line 775:
> 773:
> 774: void collect_loop_core_nodes(PhaseIdealLoop* phase, Unique_Node_List& wq) const;
> 775:
nit: why move it?
src/hotspot/share/opto/superword.cpp line 179:
> 177: assert(_packset.length() == 0, "packset must be empty");
> 178: success = SLP_extract();
> 179: if (PostLoopMultiversioning) {
Could we now have an assert for `cl->is_main_loop()` at the beginning of `SuperWord::transform_loop`, and remove all checks for it in SuperWord?
src/hotspot/share/opto/superword.cpp line 632:
> 630: cl->set_slp_pack_count(_packset.length());
> 631: }
> 632: } else {
Again: Could we now have an assert for `cl->is_main_loop()` at the beginning of `SuperWord::SLP_extract`, and remove all checks for it in SuperWord?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1239670056
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1239672094
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1239673798
More information about the hotspot-dev
mailing list