]> gcc.gnu.org Git - gcc.git/commit
builtins: Add __builtin_nextafterf16b builtin
authorJakub Jelinek <jakub@redhat.com>
Mon, 31 Oct 2022 08:07:04 +0000 (09:07 +0100)
committerJakub Jelinek <jakub@redhat.com>
Mon, 31 Oct 2022 08:07:04 +0000 (09:07 +0100)
commit29490c2a1dc00944f2420eb59374705f180a2e53
treed7575bdac07e30c9f98048935e939b6fa568a5ca
parent7f940822816917fea276654514eccdc8eacd5e93
builtins: Add __builtin_nextafterf16b builtin

The following patch adds another needed builtin.
The earlier patch adds among other things __builtin_nextafterf16
builtin which we need in order to constexpr evaluate
std::nextafter(_Float16) overload (patch for that has been posted already).
While there is inline implementation of the overload, it isn't constant
evaluation friendly, and the builtin doesn't need libm implementation
because it will be used only during constant expression evaluation.
We need the same thing also for std::nextafter(__gnu_cxx::__bfloat16_t)
though and this patch does that.

2022-10-31  Jakub Jelinek  <jakub@redhat.com>

* builtin-types.def (BT_FN_BFLOAT16_BFLOAT16_BFLOAT16): New.
* builtins.def (BUILT_IN_NEXTAFTERF16B): New builtin.
* fold-const-call.cc (fold_const_call_sss): Handle
CFN_BUILT_IN_NEXTAFTERF16B.
gcc/builtin-types.def
gcc/builtins.def
gcc/fold-const-call.cc
This page took 0.057452 seconds and 5 git commands to generate.