brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.3 KiB · a27eeab Raw
79 lines · plain
1! RUN: %python %S/test_folding.py %s %flang_fc12! Test implementations of IEEE inquiry functions3module m4  use ieee_arithmetic5  logical, parameter :: test_ieee_support_datatype = ieee_support_datatype() &6    .and. ieee_support_datatype(1.0_2) &7    .and. ieee_support_datatype(1.0_3) &8    .and. ieee_support_datatype(1.0_4) &9    .and. ieee_support_datatype(1.0_8) &10    .and. ieee_support_datatype(1.0_10) &11    .and. ieee_support_datatype(1.0_16)12  logical, parameter :: test_ieee_support_denormal = ieee_support_denormal() &13    .and. ieee_support_denormal(1.0_2) &14    .and. ieee_support_denormal(1.0_3) &15    .and. ieee_support_denormal(1.0_4) &16    .and. ieee_support_denormal(1.0_8) &17    .and. ieee_support_denormal(1.0_10) &18    .and. ieee_support_denormal(1.0_16)19  logical, parameter :: test_ieee_support_divide = ieee_support_divide() &20    .and. ieee_support_divide(1.0_2) &21    .and. ieee_support_divide(1.0_3) &22    .and. ieee_support_divide(1.0_4) &23    .and. ieee_support_divide(1.0_8) &24    .and. ieee_support_divide(1.0_10) &25    .and. ieee_support_divide(1.0_16)26  logical, parameter :: test_ieee_support_inf = ieee_support_inf() &27    .and. ieee_support_inf(1.0_2) &28    .and. ieee_support_inf(1.0_3) &29    .and. ieee_support_inf(1.0_4) &30    .and. ieee_support_inf(1.0_8) &31    .and. ieee_support_inf(1.0_10) &32    .and. ieee_support_inf(1.0_16)33  logical, parameter :: test_ieee_support_io = ieee_support_io() &34    .and. ieee_support_io(1.0_2) &35    .and. ieee_support_io(1.0_3) &36    .and. ieee_support_io(1.0_4) &37    .and. ieee_support_io(1.0_8) &38    .and. ieee_support_io(1.0_10) &39    .and. ieee_support_io(1.0_16)40  logical, parameter :: test_ieee_support_nan = ieee_support_nan() &41    .and. ieee_support_nan(1.0_2) &42    .and. ieee_support_nan(1.0_3) &43    .and. ieee_support_nan(1.0_4) &44    .and. ieee_support_nan(1.0_8) &45    .and. ieee_support_nan(1.0_10) &46    .and. ieee_support_nan(1.0_16)47  logical, parameter :: test_ieee_support_sqrt = ieee_support_sqrt() &48    .and. ieee_support_sqrt(1.0_2) &49    .and. ieee_support_sqrt(1.0_3) &50    .and. ieee_support_sqrt(1.0_4) &51    .and. ieee_support_sqrt(1.0_8) &52    .and. ieee_support_sqrt(1.0_10) &53    .and. ieee_support_sqrt(1.0_16)54#if __x86_64__55  logical, parameter :: test_ieee_support_standard = ieee_support_standard() &56    .and. ieee_support_standard(1.0_2) &57    .and. ieee_support_standard(1.0_3) &58    .and. ieee_support_standard(1.0_4) &59    .and. ieee_support_standard(1.0_8) &60    .and. ieee_support_standard(1.0_10) &61    .and. ieee_support_standard(1.0_16)62#endif63  logical, parameter :: test_ieee_support_subnormal = ieee_support_subnormal() &64    .and. ieee_support_subnormal(1.0_2) &65    .and. ieee_support_subnormal(1.0_3) &66    .and. ieee_support_subnormal(1.0_4) &67    .and. ieee_support_subnormal(1.0_8) &68    .and. ieee_support_subnormal(1.0_10) &69    .and. ieee_support_subnormal(1.0_16)70! varies by architecture71! logical, parameter :: test_ieee_support_underflow_control = .not. ieee_support_underflow_control() &72!   .and. .not. ieee_support_underflow_control(1.0_2) &73!   .and. ieee_support_underflow_control(1.0_3) &74!   .and. ieee_support_underflow_control(1.0_4) &75!   .and. ieee_support_underflow_control(1.0_8) &76!   .and. .not. ieee_support_underflow_control(1.0_10) &77!   .and. .not. ieee_support_underflow_control(1.0_16)78end module79