Ignore:
Timestamp:
May 27, 2015, 3:13:58 PM (4 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.11, master
Children:
e0938c2
Parents:
80fca28
git-author:
Joel Sherrill <joel.sherrill@…> (05/27/15 15:13:58)
git-committer:
Joel Sherrill <joel.sherrill@…> (06/15/15 18:20:17)
Message:

Remove use ticks for statistics configure option.

This was obsolete and broken based upon recent time keeping changes.

Thie build option was previously enabled by adding
USE_TICKS_FOR_STATISTICS=1 to the configure command line.

This propagated into the code as preprocessor conditionals
using the RTEMS_USE_TICKS_FOR_STATISTICS conditional.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/rtems/src/ratemonreportstatistics.c

    r80fca28 re6b31b27  
    2424#include <inttypes.h>
    2525
    26 #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    27   /* We print to 1/10's of milliseconds */
    28   #define NANOSECONDS_DIVIDER 1000
    29   #define PERCENT_FMT     "%04" PRId32
    30   #define NANOSECONDS_FMT "%06" PRId32
    31 #endif
     26/* We print to 1/10's of milliseconds */
     27#define NANOSECONDS_DIVIDER 1000
     28#define PERCENT_FMT     "%04" PRId32
     29#define NANOSECONDS_FMT "%06" PRId32
    3230
    3331void rtems_rate_monotonic_report_statistics_with_plugin(
     
    4644
    4745  (*print)( context, "Period information by period\n" );
    48   #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    49     (*print)( context, "--- CPU times are in seconds ---\n" );
    50     (*print)( context, "--- Wall times are in seconds ---\n" );
    51   #endif
     46  (*print)( context, "--- CPU times are in seconds ---\n" );
     47  (*print)( context, "--- Wall times are in seconds ---\n" );
    5248/*
    5349Layout by columns -- in memory of Hollerith :)
     
    6359\n");
    6460*/
    65   (*print)( context, "   ID     OWNER COUNT MISSED     "
    66        #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    67           "     "
    68        #endif
    69           "CPU TIME     "
    70        #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    71           "          "
    72        #endif
    73           "   WALL TIME\n"
    74   );
    75   (*print)( context, "                               "
    76        #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    77           "     "
    78        #endif
    79           "MIN/MAX/AVG    "
    80        #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    81           "          "
    82        #endif
    83           "  MIN/MAX/AVG\n"
     61  (*print)( context,
     62      "   ID     OWNER COUNT MISSED     "
     63      "     CPU TIME                  WALL TIME\n"
     64      "                               "
     65      "     MIN/MAX/AVG                MIN/MAX/AVG\n"
    8466  );
    8567
     
    127109     */
    128110    {
    129     #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    130111      struct timespec  cpu_average;
    131112      struct timespec *min_cpu = &the_stats.min_cpu_time;
     
    145126          _Timespec_Get_nanoseconds( &cpu_average ) / NANOSECONDS_DIVIDER
    146127       );
    147     #else
    148       uint32_t ival_cpu, fval_cpu;
    149 
    150       ival_cpu = the_stats.total_cpu_time * 100 / the_stats.count;
    151       fval_cpu = ival_cpu % 100;
    152       ival_cpu /= 100;
    153 
    154       (*print)( context,
    155         "%3" PRId32 "/%4" PRId32 "/%3" PRId32 ".%02" PRId32 " ",
    156         the_stats.min_cpu_time, the_stats.max_cpu_time, ival_cpu, fval_cpu
    157       );
    158     #endif
    159128    }
    160129
     
    163132     */
    164133    {
    165     #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
    166134      struct timespec  wall_average;
    167135      struct timespec *min_wall = &the_stats.min_wall_time;
     
    181149          _Timespec_Get_nanoseconds( &wall_average ) / NANOSECONDS_DIVIDER
    182150      );
    183     #else
    184       uint32_t  ival_wall, fval_wall;
    185 
    186       ival_wall = the_stats.total_wall_time * 100 / the_stats.count;
    187       fval_wall = ival_wall % 100;
    188       ival_wall /= 100;
    189       (*print)( context,
    190         "%3" PRId32 "/%4" PRId32 "/%3" PRId32 ".%02" PRId32 "\n",
    191         the_stats.min_wall_time, the_stats.max_wall_time, ival_wall, fval_wall
    192       );
    193     #endif
    194151    }
    195152  }
Note: See TracChangeset for help on using the changeset viewer.