[Flang][OpenMP]Add parsing support for DISPATCH construct (#121982)
[llvm-project.git] / compiler-rt / test / builtins / Unit / truncdfsf2_test.c
blob08a27b6d24b326467f0d4ce5579ccfcfb51b977b
1 // RUN: %clang_builtins %s %librt -o %t && %run %t
2 // REQUIRES: librt_has_truncdfsf2
4 #include <stdio.h>
6 #include "fp_test.h"
8 float __truncdfsf2(double a);
10 int test__truncdfsf2(double a)
12 float actual = __truncdfsf2(a);
13 float expected = a;
15 if (actual != expected) {
16 printf("error in test__truncdfsf2(%lf) = %f, "
17 "expected %f\n", a, actual, expected);
18 return 1;
20 return 0;
23 int main()
25 if (test__truncdfsf2(340282366920938463463374607431768211456.0))
26 return 1;
27 return 0;