https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121365

            Bug ID: 121365
           Summary: atand64(small) gets a NAN
           Product: gcc
           Version: 15.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: tydeman at tybor dot com
  Target Milestone: ---

The following code fails:
/* Prereq: dnf install libdfp-devel */
#define __STDC_WANT_DEC_FP__ 1
#define __STDC_WANT_IEC_60559_DFP_EXT__ 1

#include <assert.h>
#include <math.h>

int main(void){
  _Decimal64 dfp;

  dfp = 1.e-30D;
  dfp = atand64(dfp);
  assert( !isnan(dfp) );
  return 0;
}

Reply via email to