summaryrefslogtreecommitdiff
path: root/src/cpu/o3/regfile.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/cpu/o3/regfile.hh')
-rw-r--r--src/cpu/o3/regfile.hh12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/cpu/o3/regfile.hh b/src/cpu/o3/regfile.hh
index 117c955c2..d0f50c85c 100644
--- a/src/cpu/o3/regfile.hh
+++ b/src/cpu/o3/regfile.hh
@@ -75,6 +75,11 @@ class PhysRegFile
PhysRegFile(O3CPU *_cpu, unsigned _numPhysicalIntRegs,
unsigned _numPhysicalFloatRegs);
+ /**
+ * Destructor to free resources
+ */
+ ~PhysRegFile();
+
//Everything below should be pretty well identical to the normal
//register file that exists within AlphaISA class.
//The duplication is unfortunate but it's better than having
@@ -197,4 +202,11 @@ PhysRegFile<Impl>::PhysRegFile(O3CPU *_cpu, unsigned _numPhysicalIntRegs,
memset(floatRegFile, 0, sizeof(PhysFloatReg) * numPhysicalFloatRegs);
}
+template <class Impl>
+PhysRegFile<Impl>::~PhysRegFile()
+{
+ delete intRegFile;
+ delete floatRegFile;
+}
+
#endif