From 54a9d471faab2b4ab3ef26932957b2e0d496e84e Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Fri, 22 Dec 2017 16:14:03 -0800 Subject: arch,mem: Move page table construction into the arch classes. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This gets rid of an awkward NoArchPageTable class, and also gives the arch a place to inject ISA specific parameters (specifically page size) without having to have TheISA:: in the generic version of these types. Change-Id: I1412f303460d5c43dafdb9b3cd07af81c908a441 Reviewed-on: https://gem5-review.googlesource.com/6981 Reviewed-by: Alexandru Duțu Maintainer: Gabe Black --- src/arch/arm/process.cc | 5 ++++- src/arch/arm/process.hh | 3 --- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/arch/arm') diff --git a/src/arch/arm/process.cc b/src/arch/arm/process.cc index dcc9145d3..b64579a5d 100644 --- a/src/arch/arm/process.cc +++ b/src/arch/arm/process.cc @@ -51,6 +51,7 @@ #include "cpu/thread_context.hh" #include "debug/Stack.hh" #include "mem/page_table.hh" +#include "params/Process.hh" #include "sim/aux_vector.hh" #include "sim/byteswap.hh" #include "sim/process_impl.hh" @@ -62,8 +63,10 @@ using namespace ArmISA; ArmProcess::ArmProcess(ProcessParams *params, ObjectFile *objFile, ObjectFile::Arch _arch) - : Process(params, objFile), arch(_arch) + : Process(params, new FuncPageTable(params->name, params->pid), objFile), + arch(_arch) { + fatal_if(!params->useArchPT, "Arch page tables not implemented."); } ArmProcess32::ArmProcess32(ProcessParams *params, ObjectFile *objFile, diff --git a/src/arch/arm/process.hh b/src/arch/arm/process.hh index f8e6542ff..f4f0874c0 100644 --- a/src/arch/arm/process.hh +++ b/src/arch/arm/process.hh @@ -95,8 +95,5 @@ class ArmProcess64 : public ArmProcess void setSyscallReturn(ThreadContext *tc, SyscallReturn return_value); }; -/* No architectural page table defined for this ISA */ -typedef NoArchPageTable ArchPageTable; - #endif // __ARM_PROCESS_HH__ -- cgit v1.2.3