1 /* Test evaluation method typedefs match FLT_EVAL_METHOD. 2 Copyright (C) 2016-2022 Free Software Foundation, Inc. 3 This file is part of the GNU C Library. 4 5 The GNU C Library is free software; you can redistribute it and/or 6 modify it under the terms of the GNU Lesser General Public 7 License as published by the Free Software Foundation; either 8 version 2.1 of the License, or (at your option) any later version. 9 10 The GNU C Library is distributed in the hope that it will be useful, 11 but WITHOUT ANY WARRANTY; without even the implied warranty of 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 Lesser General Public License for more details. 14 15 You should have received a copy of the GNU Lesser General Public 16 License along with the GNU C Library; if not, see 17 <https://www.gnu.org/licenses/>. */ 18 19 #include <float.h> 20 #include <math.h> 21 22 #if FLT_EVAL_METHOD == -1 23 /* Cannot test. */ 24 typedef float_t my_float_t; 25 typedef double_t my_double_t; 26 #elif FLT_EVAL_METHOD == 0 || FLT_EVAL_METHOD == 16 27 typedef float my_float_t; 28 typedef double my_double_t; 29 #elif FLT_EVAL_METHOD == 1 30 typedef double my_float_t; 31 typedef double my_double_t; 32 #elif FLT_EVAL_METHOD == 2 33 typedef long double my_float_t; 34 typedef long double my_double_t; 35 #elif FLT_EVAL_METHOD == 32 36 typedef _Float32 my_float_t; 37 typedef double my_double_t; 38 #elif FLT_EVAL_METHOD == 33 39 typedef _Float32x my_float_t; 40 typedef _Float32x my_double_t; 41 #elif FLT_EVAL_METHOD == 64 42 typedef _Float64 my_float_t; 43 typedef _Float64 my_double_t; 44 #elif FLT_EVAL_METHOD == 65 45 typedef _Float64x my_float_t; 46 typedef _Float64x my_double_t; 47 #elif FLT_EVAL_METHOD == 128 48 typedef _Float128 my_float_t; 49 typedef _Float128 my_double_t; 50 #elif FLT_EVAL_METHOD == 129 51 typedef _Float128x my_float_t; 52 typedef _Float128x my_double_t; 53 #else 54 # error "Unknown FLT_EVAL_METHOD" 55 #endif 56 57 extern float_t test_float_t; 58 extern my_float_t test_float_t; 59 60 extern double_t test_double_t; 61 extern my_double_t test_double_t; 62 63 /* This is a compilation test. */ 64 #define TEST_FUNCTION 0 65 #include "../test-skeleton.c" 66