From c8c4f66889686d621abe9393306d3aea1fda3782 Mon Sep 17 00:00:00 2001 From: Andreas Hansson Date: Thu, 23 Apr 2015 13:37:46 -0400 Subject: misc: Appease gcc 5.1 This patch fixes a few small issues to ensure gem5 compiles when using gcc 5.1. First, the GDB_REG_BYTES in the RemoteGDB header are, rather surprisingly, flagged as unused for both ARM and X86. Removing them, however, causes compilation errors as they are actually used in the source file. Moving the constant into the class definition fixes the issue. Possibly a gcc bug. Second, we have an unused EthPktData constructor using auto_ptr, and the latter is deprecated. Since the code is never used it is simply removed. --- src/arch/arm/remote_gdb.hh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/arch/arm/remote_gdb.hh') diff --git a/src/arch/arm/remote_gdb.hh b/src/arch/arm/remote_gdb.hh index 56a50a133..1e6420633 100644 --- a/src/arch/arm/remote_gdb.hh +++ b/src/arch/arm/remote_gdb.hh @@ -76,9 +76,6 @@ enum { GDB64_NUMREGS = 98 }; -const int GDB_REG_BYTES = std::max(GDB64_NUMREGS * sizeof(uint64_t), - GDB32_NUMREGS * sizeof(uint32_t)); - class RemoteGDB : public BaseRemoteGDB { protected: @@ -89,6 +86,9 @@ class RemoteGDB : public BaseRemoteGDB void setregs(); public: + const int GDB_REG_BYTES = std::max(GDB64_NUMREGS * sizeof(uint64_t), + GDB32_NUMREGS * sizeof(uint32_t)); + RemoteGDB(System *_system, ThreadContext *tc); }; } // namespace ArmISA -- cgit v1.2.3