[libc-commits] [libc] [libc] added cos function fuzzing test (PR #101556)

Michael Jones via libc-commits libc-commits at lists.llvm.org
Thu Aug 1 14:28:25 PDT 2024


================
@@ -0,0 +1,40 @@
+//===-- cos_fuzz.cpp ----------------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+///
+/// Fuzzing test for llvm-libc cos implementation.
+///
+//===----------------------------------------------------------------------===//
+
+#include "src/math/cos.h"
+#include <cmath>
----------------
michaelrj-google wrote:

ah, I missed this in the `sin` fuzzing. This should be `math.h` instead of `cmath` and then instead of `std::isnan` it should just be `isnan` (and same for the other parts)

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


More information about the libc-commits mailing list