cpu: O3 switchFreeList checking VecElems instead of FloatRegs
authorGiacomo Travaglini <giacomo.travaglini@arm.com>
Fri, 29 Mar 2019 13:02:05 +0000 (13:02 +0000)
committerGiacomo Travaglini <giacomo.travaglini@arm.com>
Wed, 10 Apr 2019 08:41:53 +0000 (08:41 +0000)
Vector elements should be checked instead of floats since those are the
ones mapped to the vector registers.

Change-Id: I36088ab90e63720d846fcf5b43360da105b6c736
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17850
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Maintainer: Jason Lowe-Power <jason@lowepower.com>

src/cpu/o3/rename_map.cc

index 603f1ff36da098330cd4ac82103665ed64827ca7..9d912e58220e9022c0fce06747181b3dee9fb03d 100644 (file)
@@ -151,8 +151,9 @@ UnifiedRenameMap::switchFreeList(UnifiedFreeList* freeList)
         panic_if(freeList->hasFreeVecRegs(),
                 "The free list is already tracking full Vec");
         panic_if(freeList->numFreeVecElems() !=
-                regFile->numVecElemPhysRegs() - TheISA::NumFloatRegs,
-                "The free list has lost vector register elements");
+                 regFile->numVecElemPhysRegs() -
+                 TheISA::NumVecRegs * TheISA::NumVecElemPerVecReg,
+                 "The free list has lost vector register elements");
 
         auto range = regFile->getRegIds(VecRegClass);
         freeList->addRegs(range.first + TheISA::NumVecRegs, range.second);