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

Math.pow regression with power of 2 values

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 8
    • None
    • docs

      With power of 2 values Math.pow has reduced performance. The developer can work around the issue with code similar to the one below:

      if (y == 2) {
        return y * y;
      }
      return Math.pow(x, y);

            jgordon Joni Gordon (Inactive)
            azeemj Azeem Jiva
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: