source: rtems/testsuites/support/src/tmtests_support.c @ 9b4422a2

4.115
Last change on this file since 9b4422a2 was 9b4422a2, checked in by Joel Sherrill <joel.sherrill@…>, on 05/03/12 at 15:09:24

Remove All CVS Id Strings Possible Using a Script

Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines

next to each other after Id string line removed.

+ remove entire comment blocks which only exited to

contain CVS Ids

+ If the processing left a blank line at the top of

a file, it was removed.

  • Property mode set to 100644
File size: 1.1 KB
Line 
1/*
2 *  COPYRIGHT (c) 1989-2010.
3 *  On-Line Applications Research Corporation (OAR).
4 *
5 *  The license and distribution terms for this file may be
6 *  found in the file LICENSE in this distribution or at
7 *  http://www.rtems.com/license/LICENSE.
8 */
9
10#ifdef HAVE_CONFIG_H
11#include "config.h"
12#endif
13
14#include <rtems/btimer.h>
15
16#include <bsp.h>
17#include <rtems/timerdrv.h>
18#include "test_support.h"
19#include "timesys.h"
20#include "tmtests_empty_function.h"
21
22void rtems_time_test_measure_operation(
23  const char               *description,
24  rtems_time_test_method_t  operation,
25  void                     *argument,
26  int                       iterations,
27  int                       overhead
28)
29{
30  int  i;
31  uint32_t loop_overhead;
32  uint32_t end_time;
33
34  benchmark_timer_initialize();
35    for (i=0 ; i<iterations ; i++ ) {
36      benchmark_timer_empty_operation( i, argument );
37    }
38  loop_overhead = benchmark_timer_read();
39
40  benchmark_timer_initialize();
41    for (i=0 ; i<iterations ; i++ ) {
42      (*operation)( i, argument );
43    }
44  end_time = benchmark_timer_read();
45
46  put_time(
47    description,
48    end_time,
49    iterations,
50    loop_overhead,
51    overhead
52  );
53}
Note: See TracBrowser for help on using the repository browser.