[all-commits] [llvm/llvm-project] a3fb30: [mlir][math] Fix polynomial `math.asin` approximat...

Rob Suderman via All-commits all-commits at lists.llvm.org
Wed Jul 31 10:06:41 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a3fb30143565cca2c794ab0e9921d50b09cadfc7
      https://github.com/llvm/llvm-project/commit/a3fb30143565cca2c794ab0e9921d50b09cadfc7
  Author: Rob Suderman <rob.suderman at gmail.com>
  Date:   2024-07-31 (Wed, 31 Jul 2024)

  Changed paths:
    M mlir/lib/Dialect/Math/Transforms/PolynomialApproximation.cpp
    M mlir/test/mlir-cpu-runner/math-polynomial-approx.mlir

  Log Message:
  -----------
  [mlir][math] Fix polynomial `math.asin` approximation (#101247)

The polynomial approximation for asin is only good between [-9/16,
9/16]. Values beyond that range must be remapped to achieve good numeric
results. This is done by the equation below:

`arcsin(x) = PI/2 - arcsin(sqrt(1.0 - x*x))`



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list