Skip to content

Commit

Permalink
It seems that the mathematical functions are not constant.
Browse files Browse the repository at this point in the history
  • Loading branch information
philip-paul-mueller committed Nov 14, 2024
1 parent f8e2919 commit f44e50b
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions dace/runtime/include/dace/pi.h
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ namespace dace
DACE_CONSTEXPR DACE_HDFI int sin(const typeless_pi_mult& pi) noexcept
{ return 0; }

DACE_CONSTEXPR DACE_HDFI double sin(const typeless_pi_exp& pi) noexcept
DACE_HDFI double sin(const typeless_pi_exp& pi) noexcept
{ return std::sin(static_cast<double>(pi)); }

DACE_CONSTEXPR DACE_HDFI int cos(const typeless_pi&) noexcept
Expand All @@ -255,16 +255,16 @@ namespace dace
DACE_CONSTEXPR DACE_HDFI int cos(const typeless_pi_mult& pi) noexcept
{ return (pi.mult % 2 == 0) ? 1 : (-1); }

DACE_CONSTEXPR DACE_HDFI double cos(const typeless_pi_exp& pi) noexcept
DACE_HDFI double cos(const typeless_pi_exp& pi) noexcept
{ return std::cos(static_cast<double>(pi)); }


# define DEF_PI_TRIGO(F) \
DACE_CONSTEXPR DACE_HDFI double F (const typeless_pi& pi) noexcept \
{ return std:: F( static_cast<double>(pi) ); } \
DACE_CONSTEXPR DACE_HDFI double F (const typeless_pi_mult& pi) noexcept \
{ return std:: F( static_cast<double>(pi) ); } \
DACE_CONSTEXPR DACE_HDFI double F (const typeless_pi_exp& pi) noexcept \
# define DEF_PI_TRIGO(F) \
DACE_HDFI double F (const typeless_pi& pi) noexcept \
{ return std:: F( static_cast<double>(pi) ); } \
DACE_HDFI double F (const typeless_pi_mult& pi) noexcept \
{ return std:: F( static_cast<double>(pi) ); } \
DACE_HDFI double F (const typeless_pi_exp& pi) noexcept \
{ return std:: F( static_cast<double>(pi) ); }

DEF_PI_TRIGO(asin);
Expand Down

0 comments on commit f44e50b

Please sign in to comment.