summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatteo Andreozzi <Matteo.Andreozzi@arm.com>2016-02-24 04:16:55 -0500
committerMatteo Andreozzi <Matteo.Andreozzi@arm.com>2016-02-24 04:16:55 -0500
commit496a8c6c924b2b970eafa941b2617aca789ebe3c (patch)
tree90a45d9dc2ae8f362405a088e060ccd8262ea4f5 /src
parente2cea54deb1a06bb38e669937bf5f6aad24220c4 (diff)
downloadgem5-496a8c6c924b2b970eafa941b2617aca789ebe3c.tar.xz
cpu: TraceGen fix for tick frequency check
Bug fix for check on protobuf file frequency being different than global frequency. The ASCII encoder script is also fixed, and the example trace used in the regressions is updated.
Diffstat (limited to 'src')
-rw-r--r--src/cpu/testers/traffic_gen/generators.cc8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/cpu/testers/traffic_gen/generators.cc b/src/cpu/testers/traffic_gen/generators.cc
index 300bcc122..75de2f957 100644
--- a/src/cpu/testers/traffic_gen/generators.cc
+++ b/src/cpu/testers/traffic_gen/generators.cc
@@ -420,11 +420,9 @@ TraceGen::InputStream::init()
ProtoMessage::PacketHeader header_msg;
if (!trace.read(header_msg)) {
panic("Failed to read packet header from trace\n");
-
- if (header_msg.tick_freq() != SimClock::Frequency) {
- panic("Trace was recorded with a different tick frequency %d\n",
- header_msg.tick_freq());
- }
+ } else if (header_msg.tick_freq() != SimClock::Frequency) {
+ panic("Trace was recorded with a different tick frequency %d\n",
+ header_msg.tick_freq());
}
}