Daniel Carvalho has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/43004 )

Change subject: sim: Remove SimObject dependency from Drainable
......................................................................

sim: Remove SimObject dependency from Drainable

Remove this circular dependency by casting to Named
instead of SimObject.

Change-Id: Ia064f7ab1a693586b6bd0045f431512ca3c78801
Signed-off-by: Daniel R. Carvalho <oda...@yahoo.com.br>
---
M src/sim/drain.cc
1 file changed, 2 insertions(+), 2 deletions(-)



diff --git a/src/sim/drain.cc b/src/sim/drain.cc
index 3006768..f883c94 100644
--- a/src/sim/drain.cc
+++ b/src/sim/drain.cc
@@ -40,10 +40,10 @@
 #include <algorithm>

 #include "base/logging.hh"
+#include "base/named.hh"
 #include "base/trace.hh"
 #include "debug/Drain.hh"
 #include "sim/sim_exit.hh"
-#include "sim/sim_object.hh"

 DrainManager DrainManager::_instance;

@@ -71,7 +71,7 @@
     for (auto *obj : _allDrainable) {
         DrainState status = obj->dmDrain();
         if (DTRACE(Drain) && status != DrainState::Drained) {
-            SimObject *temp = dynamic_cast<SimObject*>(obj);
+            Named *temp = dynamic_cast<Named*>(obj);
             if (temp)
                 DPRINTF(Drain, "Failed to drain %s\n", temp->name());
         }

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/43004
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: Ia064f7ab1a693586b6bd0045f431512ca3c78801
Gerrit-Change-Number: 43004
Gerrit-PatchSet: 1
Gerrit-Owner: Daniel Carvalho <oda...@yahoo.com.br>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- gem5-dev@gem5.org
To unsubscribe send an email to gem5-dev-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to