Don't get it from a global constant declared in an ISA header file.
Change-Id: Ie19440abdd76500a5e12e6791e6f755ad9e95af3
Reviewed-on: https://gem5-review.googlesource.com/7344
Maintainer: Gabe Black <gabeblack@google.com>
Reviewed-by: Brandon Potter <Brandon.Potter@amd.com>
Reviewed-by: Alexandru Duțu <alexandru.dutu@amd.com>
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
: Process(params, params->useArchPT ?
static_cast<EmulationPageTable *>(
new ArchPageTable(params->name, params->pid,
- params->system, PageBytes)) :
+ params->system, PageBytes,
+ PageTableLayout)) :
new EmulationPageTable(params->name, params->pid,
PageBytes),
objFile),
public:
MultiLevelPageTable(const std::string &__name, uint64_t _pid,
- System *_sys, Addr pageSize);
+ System *_sys, Addr pageSize,
+ const std::vector<uint8_t> &layout);
~MultiLevelPageTable();
void initState(ThreadContext* tc) override;
using namespace TheISA;
template <class ISAOps>
-MultiLevelPageTable<ISAOps>::MultiLevelPageTable(const std::string &__name,
- uint64_t _pid, System *_sys,
- Addr pageSize)
+MultiLevelPageTable<ISAOps>::MultiLevelPageTable(
+ const std::string &__name, uint64_t _pid, System *_sys,
+ Addr pageSize, const std::vector<uint8_t> &layout)
: EmulationPageTable(__name, _pid, pageSize), system(_sys),
- logLevelSize(PageTableLayout),
+ logLevelSize(layout),
numLevels(logLevelSize.size())
{
}