[roll] Roll fuchsia [roll] Roll llvm-project/libc [libc][math] Implement fast path for double precision hypot function. (#204292) Compute `hypot(x, y) = sqrt(x^2 + y^2)` in double-double with relative errors < 2^-102. Using the approximation: ``` a = maximum_mag(x, y); b = minimum_mag(x, y); (hi, lo) ~ a^2 + b^2; r_hi = sqrt(hi); r_lo = (a + b - r_hi^2) * (0.5 / r_hi) ------ r_hi + r_lo ~ sqrt(x^2 + y^2). ``` Performance benchmark with CORE-MATH: Before the patch: ``` $ ./perf.sh hypot --llvm GNU libc version: 2.42 GNU libc release: stable -- CORE-MATH reciprocal throughput -- [####################] 100 % Ntrial = 20 ; Min = 23.183 + 0.311 clc/call; Median-Min = 0.319 clc/call; Max = 23.620 clc/call; -- System LIBC reciprocal throughput -- [####################] 100 % Ntrial = 20 ; Min = 14.218 + 0.299 clc/call; Median-Min = 0.193 clc/call; Max = 15.240 clc/call; -- LIBC reciprocal throughput -- [####################] 100 % Ntrial = 20 ; Min = 204.764 + 0.593 clc/call; Median-Min = 0.576 clc/call; Max = 206.057 clc/call; ``` After the patch without FMA: ``` -- LIBC reciprocal throughput -- [####################] 100 % Ntrial = 20 ; Min = 26.920 + 0.063 clc/call; Median-Min = 0.048 clc/call; Max = 27.139 clc/call; ``` After the patch with FMA: ``` -- LIBC reciprocal throughput -- [####################] 100 % Ntrial = 20 ; Min = 15.180 + 0.189 clc/call; Median-Min = 0.178 clc/call; Max = 15.461 clc/call; ``` GitOrigin-RevId: 500fc937b0f9f9dad99d0e9bfc46cf3b8706a0cf Original-Original-Revision: 64575960f928f6a79ad420f872a125cf3805d8a3 Original-Original-Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/1662481 Original-Original-Revision: bf5c5e38b411bd6e3ef34ee0effadc1a9dbcd105 GitOrigin-RevId: 47b9f3951c3f94662e8de98982e8f5a09973c871 Change-Id: Id4061fe7d01656ea3d9fad7ff71aee0a2d929975 Reviewed-on: https://fuchsia-review.googlesource.com/c/integration/+/1664300 Cr-Commit-Position: refs/heads/main@{#195078}
This repository contains Fuchsia's Global Integration manifest files.
All changes should be made to the internal version of this repository. Our infrastructure automatically updates this version when the internal one changes.
Currently all changes must be made by a Google employee. Non-Google employees wishing to make a change can ask for assistance in one of the communication channels documented at get involved.
First install Jiri.
Next run:
$ jiri init $ jiri import minimal https://fuchsia.googlesource.com/integration $ jiri update
Third party projects should have their own subdirectory in ./third_party.