[libc-commits] [libc] [libc][math][c23] Add fsub{, l, f128} and remainderf128 C23 math functions (PR #101576)

via libc-commits libc-commits at lists.llvm.org
Sat Aug 3 04:01:13 PDT 2024


================
@@ -1086,9 +1086,14 @@ template void
 explain_ternary_operation_one_output_error(Operation,
                                            const TernaryInput<long double> &,
                                            long double, double, RoundingMode);
+template void explain_ternary_operation_one_output_error(
+    Operation, const TernaryInput<double> &, float, double, RoundingMode);
+template void explain_ternary_operation_one_output_error(
+    Operation, const TernaryInput<long double> &, float, double, RoundingMode);
 
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<long double> &, double, double, RoundingMode);
+
----------------
overmighty wrote:

Nit: sorting.

You can apply this with `git apply path/to/patch.diff`.

```diff
diff --git a/libc/utils/MPFRWrapper/MPFRUtils.cpp b/libc/utils/MPFRWrapper/MPFRUtils.cpp
index 1695354565f5..ec81ea2a9d7d 100644
--- a/libc/utils/MPFRWrapper/MPFRUtils.cpp
+++ b/libc/utils/MPFRWrapper/MPFRUtils.cpp
@@ -1080,20 +1080,18 @@ void explain_ternary_operation_one_output_error(
 
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<float> &, float, double, RoundingMode);
-template void explain_ternary_operation_one_output_error(
-    Operation, const TernaryInput<double> &, double, double, RoundingMode);
-template void
-explain_ternary_operation_one_output_error(Operation,
-                                           const TernaryInput<long double> &,
-                                           long double, double, RoundingMode);
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<double> &, float, double, RoundingMode);
+template void explain_ternary_operation_one_output_error(
+    Operation, const TernaryInput<double> &, double, double, RoundingMode);
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<long double> &, float, double, RoundingMode);
-
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<long double> &, double, double, RoundingMode);
-
+template void
+explain_ternary_operation_one_output_error(Operation,
+                                           const TernaryInput<long double> &,
+                                           long double, double, RoundingMode);
 #ifdef LIBC_TYPES_HAS_FLOAT16
 template void explain_ternary_operation_one_output_error(
     Operation, const TernaryInput<float> &, float16, double, RoundingMode);
@@ -1275,15 +1273,14 @@ template bool compare_ternary_operation_one_output(Operation,
                                                    const TernaryInput<double> &,
                                                    double, double,
                                                    RoundingMode);
+template bool compare_ternary_operation_one_output(
+    Operation, const TernaryInput<long double> &, float, double, RoundingMode);
+template bool compare_ternary_operation_one_output(
+    Operation, const TernaryInput<long double> &, double, double, RoundingMode);
 template bool
 compare_ternary_operation_one_output(Operation,
                                      const TernaryInput<long double> &,
                                      long double, double, RoundingMode);
-
-template bool compare_ternary_operation_one_output(
-    Operation, const TernaryInput<long double> &, double, double, RoundingMode);
-template bool compare_ternary_operation_one_output(
-    Operation, const TernaryInput<long double> &, float, double, RoundingMode);
 #ifdef LIBC_TYPES_HAS_FLOAT16
 template bool compare_ternary_operation_one_output(Operation,
                                                    const TernaryInput<float> &,
```

https://github.com/llvm/llvm-project/pull/101576


More information about the libc-commits mailing list