summaryrefslogtreecommitdiffstats
path: root/tester/covoar/TraceList.h
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.h
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.h')
-rw-r--r--tester/covoar/TraceList.h106
1 files changed, 106 insertions, 0 deletions
diff --git a/tester/covoar/TraceList.h b/tester/covoar/TraceList.h
new file mode 100644
index 0000000..7fa1751
--- /dev/null
+++ b/tester/covoar/TraceList.h
@@ -0,0 +1,106 @@
+/*! @file TraceList.h
+ * @brief TraceList Specification
+ *
+ * This file contains the specification of the TraceList class.
+ */
+
+#ifndef __TRACE_LIST_H__
+#define __TRACE_LIST_H__
+
+#include <stdint.h>
+#include <list>
+#include <string>
+
+namespace Trace {
+
+ /*! @class TraceList
+ *
+ * This class defines XXX
+ */
+ class TraceList {
+
+ public:
+
+ /*!
+ * This enumberated type defines an exit reason
+ * for the end of a section.
+ */
+ typedef enum {
+ EXIT_REASON_BRANCH_TAKEN,
+ EXIT_REASON_BRANCH_NOT_TAKEN,
+ EXIT_REASON_OTHER
+ } exitReason_t;
+
+ /*!
+ * This type defines the information kept for each range.
+ */
+ typedef struct {
+ /*!
+ * This member variable contains the low address for the
+ * trace range.
+ */
+ uint32_t lowAddress;
+
+ /*!
+ * This member variable contains the length of the trace
+ * range.
+ */
+ uint16_t length;
+
+ /*!
+ * This member variable contains the reason that this
+ * trace range ended.
+ */
+ exitReason_t exitReason;
+ } traceRange_t;
+
+ /*!
+ * This member variable contains a list of CoverageRange instances.
+ */
+ typedef std::list<traceRange_t> ranges_t;
+
+ /*!
+ * This member variable contains a list of coverageRange
+ * instaces.
+ */
+ ranges_t set;
+
+ /*!
+ * This method constructs a TraceList instance.
+ */
+ TraceList();
+
+ /*!
+ * This method destructs a TraceList instance.
+ */
+ ~TraceList();
+
+ /*!
+ * This method adds a range entry to the set of ranges.
+ *
+ * @param[in] lowAddressArg specifies the lowest address of the range
+ * @param[in] highAddressArg specifies the highest address of the range
+ * @param[in] why specifies the reason that the range was finished
+ *
+ */
+ void add(
+ uint32_t lowAddressArg,
+ uint32_t highAddressArg,
+ exitReason_t why
+ );
+
+ /*!
+ * This method displays the trace information in the variable t.
+ */
+ void ShowTrace( traceRange_t *t);
+
+
+ /*!
+ * This method iterates through set displaying the data on the screen.
+ */
+ void ShowList();
+
+ };
+
+}
+#endif