Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8303113

C2 SuperWord: improve packing to remove _do_vector_loop

XMLWordPrintable

      The CompileCommand Vectorize / _do_vector_loop use the CloneMap to know which ops are from different ops in the single-iteration loop. This helps to eliminate some confusions when ops get packed wrongly.

      But _do_vector_loop is off by default, and in same cases makes packing impossible (e.g. for hand-unrolled loops).

      We should try to improve packing (creating adjacent memrefs, and extending) to be more robust, and cover all these cases.

      An alternative approach: try once with, and once without _do_vector_loop, and pick more profitable result. But that could double the SuperWord time, and would require us to always maintain the CloneMap.

      Related issue: JDK-8309908

      ------------------ Original Description ----------

      See discussion in PR:
      https://github.com/openjdk/jdk/pull/12350

      Also see
      https://github.com/openjdk/jdk/pull/12350#issuecomment-1469539789

      Check if these cases can be vectorized with it. Add IR tests for TestPickLastMemoryState.java.

      Consider splitting packs, when we have conversion, and one type has more elements per vector than the other.

        There are no Sub-Tasks for this issue.

            epeter Emanuel Peter
            epeter Emanuel Peter
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: