From 90378e483f36f24d346ead339ee45bf2c0680e5f Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Tue, 16 Nov 1999 16:23:26 +0000 Subject: Added BSP_MAXIMUM_OPERATION_COUNT and BSP_ITERATION_COUNT which allow the BSP to override the default number of objects that will be created in the timing tests. This is useful for reducing memory consumption on small targets. The BSP_ITERATION_COUNT can be used to reduce the number of repititions in some of the tests. This is useful for extremely slow targets (we haven't seen any slow enough to justify modifying this one yet though. :) --- testsuites/tmtests/include/timesys.h | 29 +++++++++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) (limited to 'testsuites/tmtests/include') diff --git a/testsuites/tmtests/include/timesys.h b/testsuites/tmtests/include/timesys.h index 40337e9924..8e163ba3fb 100644 --- a/testsuites/tmtests/include/timesys.h +++ b/testsuites/tmtests/include/timesys.h @@ -17,11 +17,36 @@ #include /* - * How many times a particular operation is performed while timed. + * This constant determines the maximum number of a resource + * that will be created. For example, some test create multiple + * blocking tasks to determine the execution time of blocking + * services. By default, the blocking time of 100 tasks will + * be measured. Small targets often do not have enough memory + * to create 100 tasks. By setting the BSP_MAXIMUM_OPERATION_COUNT + * to a lower number (typically 10), all of the time tests can be + * run. */ - + +#ifndef BSP_MAXIMUM_OPERATION_COUNT #define OPERATION_COUNT 100 +#else +#define OPERATION_COUNT 100 BSP_MAXIMUM_OPERATION_COUNT +#endif + +/* + * Some tests are repeated (iterated) multiple times over + * "operation count" operations. For example, a semaphore + * test may acquire and release the semaphore "operation count" + * times per loop and the body of the loop is repeated "iteration + * count" times. This value is a repitition factor which does + * not increase memory usage -- only execution time. + */ + +#ifndef BSP_ITERATION_COUNT #define IT_COUNT 100 +#else +#define IT_COUNT BSP_ITERATION_COUNT +#endif /* functions */ -- cgit v1.2.3