Changes between Version 76 and Version 77 of TBR/UserManual/RTEMS_Coverage_Analysis
- Timestamp:
- 09/22/09 00:59:42 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TBR/UserManual/RTEMS_Coverage_Analysis
v76 v77 116 116 Initially, the Baseline group included source code from the cpukit. Specifically the following cpukit directories were included: score, sapi, rtems and posix. This group represents a full tasking and synchronization feature set. What was not in the Baseline group was placed in the Developmental group. The Developmental group included: libcsupport, libfs/imfs, libmisc/stackchk, libmisc/cpuuse, libmisc/bspcmdline, libmisc/dmpbuf and libmisc/devnull. 117 117 118 Fromthe two groups, we recognized the need to use different compiler optimization levels and to analyze each group with POSIX threads enabled and POSIX threads disabled. Applying these options produced eight sub-groups that we called profiles. The eight profiles are:118 Within the two groups, we recognized the need to use different compiler optimization levels and to analyze each group with POSIX threads enabled and POSIX threads disabled. Applying these options produced eight sub-groups that we called profiles. The eight profiles are: 119 119 120 120 * Baseline (-Os, POSIX Enabled) … … 131 131 132 132 133 The compilation and configuration options that effect covmerge are set in the configuration.txt file. More information about the configuration.txt file can be found in XXX. When we started the RTEMS Code Coverage effort, the code analyzed was compiled with optimization level -Os. This optimizes for size without making the object code too difficult to follow. Following the object code is important when trying to determime how to resolve the uncovered code. Once the analyzed code approaches 100% covered, it is desirable to change the optimization level to -O2. This is the most often used optimization level.133 The compilation level and POSIX configuration options are passed as command line arguments to the RTEMS Coverage Scripts. [wiki:Developer/Coverage/HowTo RTEMS Code Coverage How To] provides details concerning how to run the RTEMS Coverage Scripts. When we started the RTEMS Code Coverage effort, the code analyzed was compiled with optimization level -Os. This optimizes for size without making the object code too difficult to follow. Following the object code is important when trying to determime how to resolve the uncovered code. Once the analyzed code approaches 100% covered, it is desirable to change the optimization level to -O2. This is the most often used optimization level. 134 134 135 135 Enabling or disabling POSIX allows us to analyze the RTEMS code in its two most commonly use threading configurations. When POSIX is enabled, RTEMS is configured to use POSIX threads and the POSIX tests are built and executed as part of the test suite. When POSIX is disabled, RTEMS is configured to use Classic RTEMS threads and the POSIX tests are not included in the test suite. … … 137 137 138 138 139 There are several compilation and configuration options that are built into the covmerge script. 140 We want the coverage build to match the default build for RTEMS. Current we're using the following configuration variables which alter the build 141 142 Inlining _Thread_Dispatch_enable, etc. 143 NDEBUG=1 - disable asserts, always keep 144 RTEMS_DO_NOT_INLINE_THREAD_ENABLE_DISPATCH=1 - resulted in branch explosion, 200+ new test cases needed to eliminate 145 RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE=1 - resulted in very difficult code to analyze, should be easy to eliminate 146 RTEMS_DO_NOT_UNROLL_THREADQ_ENQUEUE_PRIORITY=1 - unrolling loop results in multiple interrupt critical section, should be solvable 139 There are several compilation and configuration options that are built into the RTEMS Coverage Scripts and are not selectable from the command line. These options effect the RTEMS build and are used to simplify the code to aid analysis. Ideally, we would like the coverage build to match the default build for RTEMS. Over time, we will work to eliminate the need for the internal options. The current options being used are: 140 141 * NDEBUG=1 - Disables asserts. We will probably keep this option. 142 * RTEMS_DO_NOT_INLINE_THREAD_ENABLE_DISPATCH=1 - Inlining resulted in branch explosion. Over 200 new test cases will be needed to eliminate this option. 143 * RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE=1 - Inlining resulted in very difficult code to analyze. This option should be able to be eliminated. 144 * RTEMS_DO_NOT_UNROLL_THREADQ_ENQUEUE_PRIORITY=1 - Unrolling loop resulted in multiple interrupt critical sections. This option should be able to be eliminated. 147 145 = Beyond Object Code Coverage = 148 146