summaryrefslogtreecommitdiff
path: root/configs/ruby
diff options
context:
space:
mode:
authorBrad Beckmann <Brad.Beckmann@amd.com>2010-08-20 11:46:13 -0700
committerBrad Beckmann <Brad.Beckmann@amd.com>2010-08-20 11:46:13 -0700
commit9b130c153b2ce088fc0900da7290f62a06aaa30a (patch)
tree446a9902ebad9d055bda4102c78959b4e236332d /configs/ruby
parent45f6f31d7ac130867977994aa03ea723dafc867a (diff)
downloadgem5-9b130c153b2ce088fc0900da7290f62a06aaa30a.tar.xz
ruby: Improved try except blocks in ruby creation
Replaced the sys.exit in the try-except blocks with raise so that the python call stack will be printed
Diffstat (limited to 'configs/ruby')
-rw-r--r--configs/ruby/Ruby.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/configs/ruby/Ruby.py b/configs/ruby/Ruby.py
index ec1f4edf6..07a6632dd 100644
--- a/configs/ruby/Ruby.py
+++ b/configs/ruby/Ruby.py
@@ -62,11 +62,11 @@ def create_system(options, system, piobus = None, dma_devices = []):
exec "import %s" % protocol
try:
(cpu_sequencers, dir_cntrls, all_cntrls) = \
- eval("%s.create_system(options, system, piobus, dma_devices)" \
- % protocol)
+ eval("%s.create_system(options, system, piobus, dma_devices)" \
+ % protocol)
except:
print "Error: could not create sytem for ruby protocol %s" % protocol
- sys.exit(1)
+ raise
#
# Important: the topology must be created before the network and after the
@@ -74,10 +74,11 @@ def create_system(options, system, piobus = None, dma_devices = []):
#
exec "import %s" % options.topology
try:
- net_topology = eval("%s.makeTopology(all_cntrls, options)" % options.topology)
+ net_topology = eval("%s.makeTopology(all_cntrls, options)" \
+ % options.topology)
except:
print "Error: could not create topology %s" % options.topology
- sys.exit(1)
+ raise
if options.garnet_network == "fixed":
network = GarnetNetwork_d(topology = net_topology)