Skip to content

Commit

Permalink
[libc][NFC] Clean up test/src/math/differential_testing folder, renam…
Browse files Browse the repository at this point in the history
…ing it to performance_testing. (llvm#84646)

Removing all the diff tests.
  • Loading branch information
lntue authored Mar 11, 2024
1 parent 63a5dc4 commit d99bb01
Show file tree
Hide file tree
Showing 50 changed files with 88 additions and 666 deletions.
4 changes: 2 additions & 2 deletions libc/docs/math/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -567,13 +567,13 @@ Legends:
Performance
===========

* Simple performance testings are located at: `libc/test/src/math/differential_testing <https://github.com/llvm/llvm-project/tree/main/libc/test/src/math/differential_testing>`_.
* Simple performance testings are located at: `libc/test/src/math/performance_testing <https://github.com/llvm/llvm-project/tree/main/libc/test/src/math/performance_testing>`_.

* We also use the *perf* tool from the `CORE-MATH <https://core-math.gitlabpages.inria.fr/>`_
project: `link <https://gitlab.inria.fr/core-math/core-math/-/tree/master>`_.
The performance results from the CORE-MATH's perf tool are reported in the
table below, using the system library as reference (such as the `GNU C library <https://www.gnu.org/software/libc/>`_
on Linux). Fmod performance results obtained with "differential_testing".
on Linux). Fmod performance results obtained with "performance_testing".

+--------------+-------------------------------+-------------------------------+-------------------------------------+----------------------------------------------------------------------+
| <Func> | Reciprocal throughput (clk) | Latency (clk) | Testing ranges | Testing configuration |
Expand Down
8 changes: 4 additions & 4 deletions libc/src/math/docs/add_math_function.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,11 +129,11 @@ implementation (which is very often glibc).

- Add a performance test to:
```
libc/test/src/math/differential_testing/<func>_perf.cpp
libc/test/src/math/performance_testing/<func>_perf.cpp
```
- Add the corresponding entry point to:
```
libc/test/src/math/differential_testing/CMakeLists.txt
libc/test/src/math/performance_testing/CMakeLists.txt
```

## Build and Run
Expand Down Expand Up @@ -189,8 +189,8 @@ implementation (which is very often glibc).

- Build and Run performance test:
```
$ ninja libc.test.src.math.differential_testing.<func>_perf
$ projects/libc/test/src/math/differential_testing/libc.test.src.math.differential_testing.<func>_perf
$ ninja libc.test.src.math.performance_testing.<func>_perf
$ projects/libc/test/src/math/performance_testing/libc.test.src.math.performance_testing.<func>_perf
$ cat <func>_perf.log
```

Expand Down
2 changes: 1 addition & 1 deletion libc/test/src/math/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1721,5 +1721,5 @@ add_subdirectory(smoke)

if(NOT LLVM_LIBC_FULL_BUILD)
add_subdirectory(exhaustive)
add_subdirectory(differential_testing)
add_subdirectory(performance_testing)
endif()
16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/ceilf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/cosf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/exp2f_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/expf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/expm1f_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/fabsf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/floorf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/fmod_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/fmodf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/hypot_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/hypotf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/log2f_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/logbf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/logf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/nearbyintf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/rintf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/roundf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/sinf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/sqrtf_diff.cpp

This file was deleted.

16 changes: 0 additions & 16 deletions libc/test/src/math/differential_testing/truncf_diff.cpp

This file was deleted.

Loading

0 comments on commit d99bb01

Please sign in to comment.