Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2303)

Unified Diff: fusl/src/math/__sindf.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: fusl/src/math/__sindf.c
diff --git a/fusl/src/math/__sindf.c b/fusl/src/math/__sindf.c
index 8fec2a3f660c627b9dd575f96601c9530dc9a67e..82e540fb848be1bdd3841393d3777d3d9d45fe88 100644
--- a/fusl/src/math/__sindf.c
+++ b/fusl/src/math/__sindf.c
@@ -17,20 +17,18 @@
#include "libm.h"
/* |sin(x)/x - s(x)| < 2**-37.5 (~[-4.89e-12, 4.824e-12]). */
-static const double
-S1 = -0x15555554cbac77.0p-55, /* -0.166666666416265235595 */
-S2 = 0x111110896efbb2.0p-59, /* 0.0083333293858894631756 */
-S3 = -0x1a00f9e2cae774.0p-65, /* -0.000198393348360966317347 */
-S4 = 0x16cd878c3b46a7.0p-71; /* 0.0000027183114939898219064 */
+static const double S1 = -0x15555554cbac77.0p-55, /* -0.166666666416265235595 */
+ S2 = 0x111110896efbb2.0p-59, /* 0.0083333293858894631756 */
+ S3 = -0x1a00f9e2cae774.0p-65, /* -0.000198393348360966317347 */
+ S4 = 0x16cd878c3b46a7.0p-71; /* 0.0000027183114939898219064 */
-float __sindf(double x)
-{
- double_t r, s, w, z;
+float __sindf(double x) {
+ double_t r, s, w, z;
- /* Try to optimize for parallel evaluation as in __tandf.c. */
- z = x*x;
- w = z*z;
- r = S3 + z*S4;
- s = z*x;
- return (x + s*(S1 + z*S2)) + s*w*r;
+ /* Try to optimize for parallel evaluation as in __tandf.c. */
+ z = x * x;
+ w = z * z;
+ r = S3 + z * S4;
+ s = z * x;
+ return (x + s * (S1 + z * S2)) + s * w * r;
}

Powered by Google App Engine
This is Rietveld 408576698