Config: Enable using O3 CPU and Ruby in SE mode
authorNilay Vaish <nilay@cs.wisc.edu>
Mon, 23 Jan 2012 17:33:52 +0000 (11:33 -0600)
committerNilay Vaish <nilay@cs.wisc.edu>
Mon, 23 Jan 2012 17:33:52 +0000 (11:33 -0600)
configs/common/Simulation.py
configs/example/se.py
configs/ruby/MESI_CMP_directory.py

index 434fe8369c274c87a27f7cb0c84d795aed6c8684..07cc323f938a3634d4f19e6686ea062eaa3a7f71 100644 (file)
@@ -43,7 +43,7 @@ def setCPUClass(options):
     if options.cpu_type == "timing":
         class TmpClass(TimingSimpleCPU): pass
     elif options.cpu_type == "detailed":
-        if not options.caches:
+        if not options.caches and not options.ruby:
             print "O3 CPU must be used with caches"
             sys.exit(1)
         class TmpClass(DerivO3CPU): pass
index 0935a21a359f52acc16ea1a18c1bf566205d4428..57236448246d80d839e3b7d8b116f8e6daf56e31 100644 (file)
@@ -164,20 +164,13 @@ if options.cpu_type == "detailed" or options.cpu_type == "inorder":
             process += [smt_process, ]
             smt_idx += 1
     numThreads = len(workloads)
-    
+
 if options.ruby:
-    if options.cpu_type == "detailed":
-        print >> sys.stderr, "Ruby only works with TimingSimpleCPU!!"
+    if not (options.cpu_type == "detailed" or options.cpu_type == "timing"):
+        print >> sys.stderr, "Ruby requires TimingSimpleCPU or O3CPU!!"
         sys.exit(1)
-    elif not options.cpu_type == "timing":
-        print >> sys.stderr, "****WARN:  using Timing CPU since it's needed by Ruby"
-
-    class CPUClass(TimingSimpleCPU): pass
-    test_mem_mode = 'timing'
-    FutureClass = None
-else:
-    (CPUClass, test_mem_mode, FutureClass) = Simulation.setCPUClass(options)
 
+(CPUClass, test_mem_mode, FutureClass) = Simulation.setCPUClass(options)
 CPUClass.clock = '2GHz'
 CPUClass.numThreads = numThreads;
 
index 6671c307bfe6ca9431e681545c262ca4155a1977..79de421bbdc52e0efdc0a9d95afefd2ac1cbc768 100644 (file)
@@ -153,7 +153,9 @@ def create_system(options, system, piobus, dma_devices, ruby_system):
                                          cntrl_id = cntrl_count,
                                          directory = \
                                          RubyDirectoryMemory(version = i,
-                                                             size = dir_size),
+                                                             size = dir_size,
+                                                             use_map =
+                                                           options.use_map),
                                          memBuffer = mem_cntrl,
                                          ruby_system = ruby_system)