diff options
author | Yaxun (Sam) Liu <yaxun.liu@amd.com> | 2023-07-09 01:19:34 -0400 |
---|---|---|
committer | Yaxun (Sam) Liu <yaxun.liu@amd.com> | 2023-07-25 10:04:31 -0400 |
commit | a0709e226b482c3d4a2d1f15227641590c43527a (patch) | |
tree | 7c46cd72c666d7aedd6acdfe8d72216069d279ba /llvm/tools/llvm-objdump/llvm-objdump.cpp | |
parent | e93cbd18c11281465246060d6c2a9ea1deae3360 (diff) | |
download | llvm-a0709e226b482c3d4a2d1f15227641590c43527a.zip llvm-a0709e226b482c3d4a2d1f15227641590c43527a.tar.gz llvm-a0709e226b482c3d4a2d1f15227641590c43527a.tar.bz2 |
[HIP] Use native math functions for `-fcuda-approx-transcendentals`
CUDA allows replacing standard math functions with less accurate
native math functions when -use_fast_math is specified
(https://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html#intrinsic-functions).
Cuda-clang does this when -fcuda-approx-transcendentals
or -ffast-math is specified. HIP-clang currently passes option
-fcuda-approx-transcendentals to clang -cc1 and predefines
__CLANG_CUDA_APPROX_TRANSCENDENTALS__ but does
not replace standard math functions with native math functions.
This patch implements this in a similar approach as cuda-clang.
Reviewed by: Brian Sumner, Matt Arsenault
Differential Revision: https://reviews.llvm.org/D154790
Diffstat (limited to 'llvm/tools/llvm-objdump/llvm-objdump.cpp')
0 files changed, 0 insertions, 0 deletions