Changeset b2acdf32 in mainline for uspace/app/tester/float/float2.c


Ignore:
Timestamp:
2018-08-29T20:05:52Z (7 years ago)
Author:
Jiří Zárevúcky <jiri.zarevucky@…>
Children:
184ff675
Parents:
b1b201f
git-author:
Jiří Zárevúcky <jiri.zarevucky@…> (2018-08-29 15:48:16)
git-committer:
Jiří Zárevúcky <jiri.zarevucky@…> (2018-08-29 20:05:52)
Message:

Remove unused and not well tested atan()/atan2()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/tester/float/float2.c

    rb1b201f rb2acdf32  
    4343};
    4444
    45 static double arguments_atan[OPERANDS] = {
    46         3.5, 100.0, 50.0, 768.3156, 1080.499999, 1.0, 66.0,
    47         2.718281828459045, 9.9, 0.001
    48 };
    49 
    5045static double arguments_exp[OPERANDS] = {
    5146        3.5, -2.1, 50.0, 0.0, 1.0, 13.2, -1.1, -5.5, 0.1, -66.0
     
    6459static double arguments_tanh[OPERANDS] = {
    6560        3.5, -2.1, 50.0, 0.0, 1.0, 13.2, -1.1, -5.5, 0.000001, -66000000.0
    66 };
    67 
    68 static double results_atan[OPERANDS] = {
    69         1.292496667790, 1.560796660108, 1.550798992822, 1.569494779052,
    70         1.569870829603, 0.785398163397, 1.555645970920, 1.218282905017,
    71         1.470127674637, 0.000999999667
    7261};
    7362
     
    193182
    194183        for (unsigned int i = 0; i < OPERANDS; i++) {
    195                 double res = atan(arguments_atan[i]);
    196 
    197                 if (!cmp_double(res, results_atan[i])) {
    198                         TPRINTF("Double precision atan failed "
    199                             "(%.12lf != %.12lf, arg %u)\n", res, results_atan[i], i);
    200                         fail = true;
    201                 }
    202         }
    203 
    204         for (unsigned int i = 0; i < OPERANDS; i++) {
    205                 float res = atanf(arguments_atan[i]);
    206 
    207                 if (!cmp_float(res, results_atan[i])) {
    208                         TPRINTF("Single precision atan failed "
    209                             "(%f != %lf, arg %u)\n", res, results_atan[i], i);
    210                         fail = true;
    211                 }
    212         }
    213 
    214         for (unsigned int i = 0; i < OPERANDS; i++) {
    215184                double res = ceil(arguments[i]);
    216185
Note: See TracChangeset for help on using the changeset viewer.