summaryrefslogtreecommitdiffstats
path: root/tester/covoar/TraceList.cc
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2014-05-09 21:50:37 +1000
committerChris Johns <chrisj@rtems.org>2014-06-18 16:48:08 +1200
commit100f517ab37265acdf067e36b6860020ec8b2184 (patch)
tree2316c8b888e11dcbcfbfc66a0c1e31991ea20656 /tester/covoar/TraceList.cc
parent4.11: Add ntp patch. (diff)
downloadrtems-tools-100f517ab37265acdf067e36b6860020ec8b2184.tar.bz2
covoar: Merger the covoar source from rtems-testing.git.
Use waf to build covoar.
Diffstat (limited to 'tester/covoar/TraceList.cc')
-rw-r--r--tester/covoar/TraceList.cc50
1 files changed, 50 insertions, 0 deletions
diff --git a/tester/covoar/TraceList.cc b/tester/covoar/TraceList.cc
new file mode 100644
index 0000000..514813b
--- /dev/null
+++ b/tester/covoar/TraceList.cc
@@ -0,0 +1,50 @@
+#include "TraceList.h"
+#include <stdio.h>
+
+namespace Trace {
+
+ TraceList::TraceList()
+ {
+ }
+
+ TraceList::~TraceList()
+ {
+ }
+
+ void TraceList::add(
+ uint32_t lowAddressArg,
+ uint32_t highAddressArg,
+ exitReason_t why
+ )
+ {
+ traceRange_t t;
+
+ t.lowAddress = lowAddressArg;
+ t.length = highAddressArg - lowAddressArg;
+ t.exitReason = why;
+
+ set.push_back( t );
+ }
+
+ void TraceList::ShowTrace( traceRange_t *t)
+ {
+ printf(
+ "Start 0x%x, length 0x%03x Reason %d\n",
+ t->lowAddress,
+ t->length,
+ t->exitReason
+ );
+ }
+
+ void TraceList::ShowList()
+ {
+ ranges_t::iterator ritr;
+ traceRange_t t;
+
+ for ( ritr=set.begin(); ritr != set.end(); ritr++ ) {
+ t = *ritr;
+ ShowTrace( &t );
+ }
+ }
+
+}