anatol commented on code in PR #3830:
URL: https://github.com/apache/nuttx-apps/pull/3830#discussion_r4247671414


##########
testing/libc/fmaf/Kconfig:
##########
@@ -0,0 +1,13 @@
+#
+# For a description of the syntax of this configuration file,
+# see the file kconfig-language.txt in the NuttX tools repository.
+#
+
+config TESTING_FMAF
+       tristate "fmaf() test"
+       default n
+       depends on LIBM_NEWLIB

Review Comment:
   I might be a leftover from my development. it seems unneeded



##########
testing/libc/fmaf/CMakeLists.txt:
##########
@@ -0,0 +1,39 @@
+# 
##############################################################################
+# apps/testing/libc/fmaf/CMakeLists.txt
+#
+# SPDX-License-Identifier: Apache-2.0
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more 
contributor
+# license agreements.  See the NOTICE file distributed with this work for
+# additional information regarding copyright ownership.  The ASF licenses this
+# file to you under the Apache License, Version 2.0 (the "License"); you may 
not
+# use this file except in compliance with the License.  You may obtain a copy 
of
+# the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+# 
##############################################################################
+
+if(CONFIG_TESTING_FMAF)
+  nuttx_add_application(
+    NAME
+    fmaf_test
+    STACKSIZE
+    ${CONFIG_DEFAULT_TASK_STACKSIZE}
+    MODULE
+    ${CONFIG_TESTING_FMAF}
+    COMPILE_FLAGS
+    -frounding-math
+    -ffp-contract=off

Review Comment:
   See See test_fmaf.c. It is needed as we call fesetround() to check different 
rounding modes.
   
   
   
https://support.arm.com/documentation/107976/21-1-1/Clang-reference/clang-command-line-options/-frounding-math---fno-rounding-math
   
   According to RiscV docs FMADD.S supports 4 dynamic rounding modes and the 
host test simulates the behavior
   https://docs.riscv.org/reference/isa/_attachments/riscv-unprivileged.pdf
   
   
   



##########
testing/libc/fmaf/test_fmaf_impl.c:
##########
@@ -0,0 +1,28 @@
+/****************************************************************************
+ * testing/libc/fmaf/test_fmaf_impl.c

Review Comment:
   done



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to