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

Missing Identity transforms for VectorAPI operations MUL, ADD, SUB, DIV

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • None
    • hotspot
    • generic
    • generic

      Missing VAPI Identity transforms for MUL, ADD, SUB, DIV.
       
      X + 0 = X
      X * 1 = X
      X – 0 = X
      X * 0 = 0
      X / X = 1 (only integral types, since floating point types have different semantics for special values for mod and division operations)

      Such cases do not create issues in auto-vectorization flow since existing idealizations on scalar nodes optimize the expressions upfront.

      Other distributive property applications
      A * B + A * C = A * (B + C)
      Since multiplication is costly in comparison to addition

      JDK-8358521 will be able to handle subset of such expression if both the operations involve scalar broadcasting

            jbhateja Jatin Bhateja
            jbhateja Jatin Bhateja
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: