diff options
author | Ryan Long <ryan.long@oarcorp.com> | 2021-07-13 15:18:29 -0400 |
---|---|---|
committer | Joel Sherrill <joel@rtems.org> | 2021-09-07 14:26:51 -0500 |
commit | 065b76e615e9f59da5e083126566f55f0178acb7 (patch) | |
tree | 3c54f57ba845d727b2d9088c6b7af4daa08d6635 /tester | |
parent | CoverageMapBase.h: Fix formatting (diff) | |
download | rtems-tools-065b76e615e9f59da5e083126566f55f0178acb7.tar.bz2 |
CoverageReaderQEMU.cc: Fix formatting
Diffstat (limited to 'tester')
-rw-r--r-- | tester/covoar/CoverageReaderQEMU.cc | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/tester/covoar/CoverageReaderQEMU.cc b/tester/covoar/CoverageReaderQEMU.cc index cef09b3..53d8041 100644 --- a/tester/covoar/CoverageReaderQEMU.cc +++ b/tester/covoar/CoverageReaderQEMU.cc @@ -68,10 +68,10 @@ namespace Coverage { // Read ENTRIES number of trace entries. // #define ENTRIES 1024 - while (true) { - CoverageMapBase *aCoverageMap = NULL; + while ( true ) { + CoverageMapBase* aCoverageMap = NULL; struct trace_entry entries[ENTRIES]; - struct trace_entry *entry; + struct trace_entry* entry; // Read and process each line of the coverage file. traceFile.read( (char *) entries, sizeof( struct trace_entry ) ); @@ -90,31 +90,31 @@ namespace Coverage { aCoverageMap = executableInformation->getCoverageMap( entry->pc ); // Ensure that coverage map exists. - if (!aCoverageMap) + if ( !aCoverageMap ) continue; // Set was executed for each TRACE_OP_BLOCK - if (entry->op & TRACE_OP_BLOCK) { - for (i=0; i<entry->size; i++) { + if ( entry->op & TRACE_OP_BLOCK ) { + for ( i = 0; i < entry->size; i++ ) { aCoverageMap->setWasExecuted( entry->pc + i ); } } // Determine if additional branch information is available. - if ( (entry->op & branchInfo) != 0 ) { + if ( ( entry->op & branchInfo ) != 0 ) { uint32_t a = entry->pc + entry->size - 1; - while (a > entry->pc && !aCoverageMap->isStartOfInstruction(a)) + while ( a > entry->pc && !aCoverageMap->isStartOfInstruction( a ) ) a--; - if (a == entry->pc && !aCoverageMap->isStartOfInstruction(a)) { + if ( a == entry->pc && !aCoverageMap->isStartOfInstruction( a ) ) { // Something went wrong parsing the objdump. std::ostringstream what; what << "Reached beginning of range in " << file << " at " << entry->pc << " with no start of instruction."; throw rld::error( what, "CoverageReaderQEMU::processFile" ); } - if (entry->op & taken) { + if ( entry->op & taken ) { aCoverageMap->setWasTaken( a ); - } else if (entry->op & notTaken) { + } else if ( entry->op & notTaken ) { aCoverageMap->setWasNotTaken( a ); } } |