diff options
author | Antonio Sanchez <cantonios@google.com> | 2020-12-22 22:49:06 -0800 |
---|---|---|
committer | Antonio Sanchez <cantonios@google.com> | 2020-12-22 23:25:23 -0800 |
commit | 070d303d56d46d2e018a58214da24ca629ea454f (patch) | |
tree | 3dfa72bf48ffdca0a67bd794596e4e452d50ed19 /test/sparse_vector.cpp | |
parent | fdf2ee62c5174441076fb64c9737d89bbe102759 (diff) |
Add CUDA complex sqrt.
This is to support scalar `sqrt` of complex numbers `std::complex<T>` on
device, requested by Tensorflow folks.
Technically `std::complex` is not supported by NVCC on device
(though it is by clang), so the default `sqrt(std::complex<T>)` function only
works on the host. Here we create an overload to add back the
functionality.
Also modified the CMake file to add `--relaxed-constexpr` (or
equivalent) flag for NVCC to allow calling constexpr functions from
device functions, and added support for specifying compute architecture for
NVCC (was already available for clang).
Diffstat (limited to 'test/sparse_vector.cpp')
0 files changed, 0 insertions, 0 deletions