From 22b60c57e697289baa205f11b164f356363c2bee Mon Sep 17 00:00:00 2001 From: Gedare Bloom Date: Tue, 21 May 2013 11:40:11 -0500 Subject: x86: Squash outstanding walks when instructions are squashed. This is the x86 version of the ARM changeset baa17ba80e06. In case an instruction has been squashed by the o3 cpu, this patch allows page table walker to avoid carrying out a pending translation that the instruction requested for. --- src/arch/x86/pagetable_walker.hh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/arch/x86/pagetable_walker.hh') diff --git a/src/arch/x86/pagetable_walker.hh b/src/arch/x86/pagetable_walker.hh index c2781ca1b..c6766689b 100644 --- a/src/arch/x86/pagetable_walker.hh +++ b/src/arch/x86/pagetable_walker.hh @@ -87,6 +87,7 @@ namespace X86ISA // State to track each walk of the page table class WalkerState { + friend class Walker; private: enum State { Ready, @@ -176,6 +177,12 @@ namespace X86ISA System * sys; MasterID masterId; + // The number of outstanding walks that can be squashed per cycle. + unsigned numSquashable; + + // Wrapper for checking for squashes before starting a translation. + void startWalkWrapper(); + // Functions for dealing with packets. bool recvTimingResp(PacketPtr pkt); void recvRetry(); @@ -199,7 +206,8 @@ namespace X86ISA Walker(const Params *params) : MemObject(params), port(name() + ".port", this), funcState(this, NULL, NULL, true), tlb(NULL), sys(params->system), - masterId(sys->getMasterId(name())) + masterId(sys->getMasterId(name())), + numSquashable(params->num_squash_per_cycle) { } }; -- cgit v1.2.3