Deleted Added
sdiff udiff text old ( 7902:aafb4a7384d4 ) new ( 8953:488d45aeb672 )
full compact
1/*
2 * Copyright (c) 2007 The Hewlett-Packard Development Company
3 * All rights reserved.
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 31 unchanged lines hidden (view full) ---

40#include "arch/x86/isa_traits.hh"
41#include "arch/x86/pagetable.hh"
42#include "sim/serialize.hh"
43
44namespace X86ISA
45{
46
47TlbEntry::TlbEntry(Addr asn, Addr _vaddr, Addr _paddr) :
48 paddr(_paddr), vaddr(_vaddr), logBytes(PageShift), writable(true),
49 user(true), uncacheable(false), global(false), patBit(0), noExec(false)
50{}
51
52void
53TlbEntry::serialize(std::ostream &os)
54{
55 SERIALIZE_SCALAR(paddr);
56 SERIALIZE_SCALAR(vaddr);
57 SERIALIZE_SCALAR(logBytes);
58 SERIALIZE_SCALAR(writable);
59 SERIALIZE_SCALAR(user);
60 SERIALIZE_SCALAR(uncacheable);
61 SERIALIZE_SCALAR(global);
62 SERIALIZE_SCALAR(patBit);
63 SERIALIZE_SCALAR(noExec);
64 SERIALIZE_SCALAR(lruSeq);
65}
66
67void
68TlbEntry::unserialize(Checkpoint *cp, const std::string &section)
69{
70 UNSERIALIZE_SCALAR(paddr);
71 UNSERIALIZE_SCALAR(vaddr);
72 UNSERIALIZE_SCALAR(logBytes);
73 UNSERIALIZE_SCALAR(writable);
74 UNSERIALIZE_SCALAR(user);
75 UNSERIALIZE_SCALAR(uncacheable);
76 UNSERIALIZE_SCALAR(global);
77 UNSERIALIZE_SCALAR(patBit);
78 UNSERIALIZE_SCALAR(noExec);
79 UNSERIALIZE_SCALAR(lruSeq);
80}
81
82}