summaryrefslogtreecommitdiff
path: root/src/arch/alpha
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2019-04-24 17:19:23 -0700
committerGabe Black <gabeblack@google.com>2019-04-28 03:09:09 +0000
commitfce9c7a26f8c8a29d51c319c876a7bf0a32404a7 (patch)
tree61cf66e892473fafab9e0e7726750542a0be92b0 /src/arch/alpha
parentcdcc55a6a8fe9b4625b316a8d8845366ccfa71c9 (diff)
downloadgem5-fce9c7a26f8c8a29d51c319c876a7bf0a32404a7.tar.xz
mem: Remove the ISA specialized versions of port proxy's read/write.
These selected their behavior based on ifdefs and had to be disabled when on the NULL ISA. The versions which take an explicit endianness have been renamed to just read/write instead of readGtoH and writeHtoG since the direction of the translation is obvious from context. Change-Id: I6cfbfda6c4481962d442d3370534e50532d41814 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/18372 Reviewed-by: Gabe Black <gabeblack@google.com> Maintainer: Gabe Black <gabeblack@google.com> Tested-by: kokoro <noreply+kokoro@google.com>
Diffstat (limited to 'src/arch/alpha')
-rw-r--r--src/arch/alpha/linux/system.cc3
-rw-r--r--src/arch/alpha/stacktrace.cc14
2 files changed, 9 insertions, 8 deletions
diff --git a/src/arch/alpha/linux/system.cc b/src/arch/alpha/linux/system.cc
index 3ecf42f0b..33e760fe5 100644
--- a/src/arch/alpha/linux/system.cc
+++ b/src/arch/alpha/linux/system.cc
@@ -181,7 +181,8 @@ LinuxAlphaSystem::setDelayLoop(ThreadContext *tc)
Tick cpuFreq = tc->getCpuPtr()->frequency();
assert(intrFreq);
FSTranslatingPortProxy &vp = tc->getVirtProxy();
- vp.writeHtoG(addr, (uint32_t)((cpuFreq / intrFreq) * 0.9988));
+ vp.write(addr, (uint32_t)((cpuFreq / intrFreq) * 0.9988),
+ GuestByteOrder);
}
}
diff --git a/src/arch/alpha/stacktrace.cc b/src/arch/alpha/stacktrace.cc
index 3c302d27d..dfe74742e 100644
--- a/src/arch/alpha/stacktrace.cc
+++ b/src/arch/alpha/stacktrace.cc
@@ -54,23 +54,23 @@ ProcessInfo::ProcessInfo(ThreadContext *_tc)
if (!symtab->findAddress("thread_info_size", addr))
panic("thread info not compiled into kernel\n");
- thread_info_size = vp.readGtoH<int32_t>(addr);
+ thread_info_size = vp.read<int32_t>(addr, GuestByteOrder);
if (!symtab->findAddress("task_struct_size", addr))
panic("thread info not compiled into kernel\n");
- task_struct_size = vp.readGtoH<int32_t>(addr);
+ task_struct_size = vp.read<int32_t>(addr, GuestByteOrder);
if (!symtab->findAddress("thread_info_task", addr))
panic("thread info not compiled into kernel\n");
- task_off = vp.readGtoH<int32_t>(addr);
+ task_off = vp.read<int32_t>(addr, GuestByteOrder);
if (!symtab->findAddress("task_struct_pid", addr))
panic("thread info not compiled into kernel\n");
- pid_off = vp.readGtoH<int32_t>(addr);
+ pid_off = vp.read<int32_t>(addr, GuestByteOrder);
if (!symtab->findAddress("task_struct_comm", addr))
panic("thread info not compiled into kernel\n");
- name_off = vp.readGtoH<int32_t>(addr);
+ name_off = vp.read<int32_t>(addr, GuestByteOrder);
}
Addr
@@ -83,7 +83,7 @@ ProcessInfo::task(Addr ksp) const
Addr tsk;
FSTranslatingPortProxy &vp = tc->getVirtProxy();
- tsk = vp.readGtoH<Addr>(base + task_off);
+ tsk = vp.read<Addr>(base + task_off, GuestByteOrder);
return tsk;
}
@@ -98,7 +98,7 @@ ProcessInfo::pid(Addr ksp) const
uint16_t pd;
FSTranslatingPortProxy &vp = tc->getVirtProxy();
- pd = vp.readGtoH<uint16_t>(task + pid_off);
+ pd = vp.read<uint16_t>(task + pid_off, GuestByteOrder);
return pd;
}