From 5a27431b969ed0557d2a079066d082153f97af9d Mon Sep 17 00:00:00 2001 From: Nathan Binkert Date: Sat, 4 Aug 2007 16:06:19 -0700 Subject: [PATCH] python: use the enum values in the memory mode changing code --HG-- extra : convert_revision : 2e399b2b407922ad076f93d33af73e3ba4c05218 --- src/python/m5/simulate.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/python/m5/simulate.py b/src/python/m5/simulate.py index c703664d4..6db25f0ed 100644 --- a/src/python/m5/simulate.py +++ b/src/python/m5/simulate.py @@ -148,20 +148,20 @@ def changeToAtomic(system): if not isinstance(system, (objects.Root, objects.System)): raise TypeError, "Parameter of type '%s'. Must be type %s or %s." % \ (type(system), objects.Root, objects.System) - if system.getMemoryMode() != objects.params.SimObject.Atomic: + if system.getMemoryMode() != objects.params.atomic: doDrain(system) print "Changing memory mode to atomic" - system.changeTiming(objects.params.SimObject.Atomic) + system.changeTiming(objects.params.atomic) def changeToTiming(system): if not isinstance(system, (objects.Root, objects.System)): raise TypeError, "Parameter of type '%s'. Must be type %s or %s." % \ (type(system), objects.Root, objects.System) - if system.getMemoryMode() != objects.params.SimObject.Timing: + if system.getMemoryMode() != objects.params.timing: doDrain(system) print "Changing memory mode to timing" - system.changeTiming(objects.params.SimObject.Timing) + system.changeTiming(objects.params.timing) def switchCpus(cpuList): print "switching cpus" -- 2.30.2