isa.cc (7533:b4aa25440bdd) isa.cc (9372:7ba317c33683)
1/*
2 * Copyright (c) 2009 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

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

122}
123
124MiscReg
125ISA::readMiscReg(int miscReg, ThreadContext * tc)
126{
127 if (miscReg == MISCREG_TSC) {
128 return regVal[MISCREG_TSC] + tc->getCpuPtr()->curCycle();
129 }
1/*
2 * Copyright (c) 2009 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

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

122}
123
124MiscReg
125ISA::readMiscReg(int miscReg, ThreadContext * tc)
126{
127 if (miscReg == MISCREG_TSC) {
128 return regVal[MISCREG_TSC] + tc->getCpuPtr()->curCycle();
129 }
130
131 if (miscReg == MISCREG_FSW) {
132 MiscReg fsw = regVal[MISCREG_FSW];
133 MiscReg top = regVal[MISCREG_X87_TOP];
134 return (fsw & (~(7ULL << 11))) + (top << 11);
135 }
136
130 return readMiscRegNoEffect(miscReg);
131}
132
133void
134ISA::setMiscRegNoEffect(int miscReg, MiscReg val)
135{
136 // Make sure we're not dealing with an illegal control register.
137 // Instructions should filter out these indexes, and nothing else should

--- 225 unchanged lines hidden ---
137 return readMiscRegNoEffect(miscReg);
138}
139
140void
141ISA::setMiscRegNoEffect(int miscReg, MiscReg val)
142{
143 // Make sure we're not dealing with an illegal control register.
144 // Instructions should filter out these indexes, and nothing else should

--- 225 unchanged lines hidden ---