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

Optimize abs operations in C2 compiler

    XMLWordPrintable

Details

    • 16
    • b06
    • generic
    • generic

    Description

      In current SLP, the vectorization of Math.abs() with char type is intentionally disabled after JDK-8261022 because it generates incorrect result before.

      But in Java semantics, as the char type is always non-negative, we could actually translate Math.abs(char) to a no-op by adding a no-op IR and matching rules somehow.

      We can consider re-enable Math.abs() vectorization with char type.

      Attachments

        Issue Links

          Activity

            People

              pli Pengfei Li
              pli Pengfei Li
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: