diff options
author | Gabe Black <gblack@eecs.umich.edu> | 2006-03-14 16:08:32 -0500 |
---|---|---|
committer | Gabe Black <gblack@eecs.umich.edu> | 2006-03-14 16:08:32 -0500 |
commit | fa763d2ecfae16e84a9f9d689d19f746d84d08e3 (patch) | |
tree | 52474edfd8d1ab010a376b1eb66f4d9990fe4a54 /cpu/o3/cpu.cc | |
parent | f045b110cf1db6f9fc70589532b48d9cca339897 (diff) | |
parent | efe46430fac2419a02062e3b282324498a55df28 (diff) | |
download | gem5-fa763d2ecfae16e84a9f9d689d19f746d84d08e3.tar.xz |
Merge m5.eecs.umich.edu:/bk/newmem
into ewok.(none):/home/gblack/m5/newmem
cpu/cpu_exec_context.cc:
Hand merge
--HG--
rename : arch/alpha/registerfile.hh => arch/alpha/regfile.hh
extra : convert_revision : bd18966f7c37c67c2bc7ca2633b58f70ce64409c
Diffstat (limited to 'cpu/o3/cpu.cc')
-rw-r--r-- | cpu/o3/cpu.cc | 47 |
1 files changed, 30 insertions, 17 deletions
diff --git a/cpu/o3/cpu.cc b/cpu/o3/cpu.cc index 62d68bb33..a268dbc23 100644 --- a/cpu/o3/cpu.cc +++ b/cpu/o3/cpu.cc @@ -258,8 +258,7 @@ FullO3CPU<Impl>::init() // Then loop through the floating point registers. for (int i = 0; i < TheISA::NumFloatRegs; ++i) { - regFile.floatRegFile[i].d = src_xc->readFloatRegDouble(i); - regFile.floatRegFile[i].q = src_xc->readFloatRegInt(i); + regFile.floatRegFile.setRegBits(i, src_xc->readRegBits(i)) } /* // Then loop through the misc registers. @@ -348,24 +347,31 @@ FullO3CPU<Impl>::readIntReg(int reg_idx) } template <class Impl> -float -FullO3CPU<Impl>::readFloatRegSingle(int reg_idx) +FloatReg +FullO3CPU<Impl>::readFloatReg(int reg_idx, int width) { - return regFile.readFloatRegSingle(reg_idx); + return regFile.readFloatReg(reg_idx, width); } template <class Impl> -double -FullO3CPU<Impl>::readFloatRegDouble(int reg_idx) +FloatReg +FullO3CPU<Impl>::readFloatReg(int reg_idx) { - return regFile.readFloatRegDouble(reg_idx); + return regFile.readFloatReg(reg_idx); } template <class Impl> -uint64_t -FullO3CPU<Impl>::readFloatRegInt(int reg_idx) +FloatRegBits +FullO3CPU<Impl>::readFloatRegBits(int reg_idx, int width) +{ + return regFile.readFloatRegBits(reg_idx, width); +} + +template <class Impl> +FloatRegBits +FullO3CPU<Impl>::readFloatRegBits(int reg_idx) { - return regFile.readFloatRegInt(reg_idx); + return regFile.readFloatRegBits(reg_idx); } template <class Impl> @@ -377,23 +383,30 @@ FullO3CPU<Impl>::setIntReg(int reg_idx, uint64_t val) template <class Impl> void -FullO3CPU<Impl>::setFloatRegSingle(int reg_idx, float val) +FullO3CPU<Impl>::setFloatReg(int reg_idx, FloatReg val, int width) +{ + regFile.setFloatReg(reg_idx, val, width); +} + +template <class Impl> +void +FullO3CPU<Impl>::setFloatReg(int reg_idx, FloatReg val) { - regFile.setFloatRegSingle(reg_idx, val); + regFile.setFloatReg(reg_idx, val); } template <class Impl> void -FullO3CPU<Impl>::setFloatRegDouble(int reg_idx, double val) +FullO3CPU<Impl>::setFloatRegBits(int reg_idx, FloatRegBits val, int width) { - regFile.setFloatRegDouble(reg_idx, val); + regFile.setFloatRegBits(reg_idx, val, width); } template <class Impl> void -FullO3CPU<Impl>::setFloatRegInt(int reg_idx, uint64_t val) +FullO3CPU<Impl>::setFloatRegBits(int reg_idx, FloatRegBits val) { - regFile.setFloatRegInt(reg_idx, val); + regFile.setFloatRegBits(reg_idx, val); } template <class Impl> |