From ecec88750729b2c94d5ca9dedbf7a755c46c41a7 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 16 Jan 2018 01:25:39 -0800 Subject: sim, arch, base: Refactor the base remote GDB class. Fold the GDBListener class into the main BaseRemoteGDB class, move around a bunch of functions, convert a lot of internal functions to be private, move some functions into the .cc, make some functions non-virtual which didn't really need to be overridden. Change-Id: Id0832b730b0fdfb2eababa5067e72c66de1c147d Reviewed-on: https://gem5-review.googlesource.com/7422 Reviewed-by: Jason Lowe-Power Reviewed-by: Gabe Black Maintainer: Gabe Black --- src/arch/sparc/remote_gdb.hh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'src/arch/sparc/remote_gdb.hh') diff --git a/src/arch/sparc/remote_gdb.hh b/src/arch/sparc/remote_gdb.hh index 653f0b113..f0ddd54e1 100644 --- a/src/arch/sparc/remote_gdb.hh +++ b/src/arch/sparc/remote_gdb.hh @@ -69,7 +69,11 @@ class RemoteGDB : public BaseRemoteGDB size_t size() const { return sizeof(r); } void getRegs(ThreadContext*); void setRegs(ThreadContext*) const; - const std::string name() const { return gdb->name() + ".SPARCGdbRegCache"; } + const std::string + name() const + { + return gdb->name() + ".SPARCGdbRegCache"; + } }; class SPARC64GdbRegCache : public BaseGdbRegCache @@ -91,14 +95,18 @@ class RemoteGDB : public BaseRemoteGDB size_t size() const { return sizeof(r); } void getRegs(ThreadContext*); void setRegs(ThreadContext*) const; - const std::string name() const { return gdb->name() + ".SPARC64GdbRegCache"; } + const std::string + name() const + { + return gdb->name() + ".SPARC64GdbRegCache"; + } }; SPARCGdbRegCache regCache32; SPARC64GdbRegCache regCache64; public: - RemoteGDB(System *_system, ThreadContext *tc); + RemoteGDB(System *_system, ThreadContext *tc, int _port); BaseGdbRegCache *gdbRegs(); }; } // namespace SparcISA -- cgit v1.2.3