From 91c005648151cd6010beed81e8113cfaec71ffba Mon Sep 17 00:00:00 2001 From: Nikos Nikoleris Date: Thu, 23 Apr 2020 17:26:02 +0100 Subject: [PATCH] arch-arm: Downgrade constexpr causing build errors to const Change-Id: Idf5ae62603b6181d44aaaef91b774fa7b26eb718 Signed-off-by: Nikos Nikoleris Reviewed-by: Giacomo Travaglini Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/28167 Tested-by: kokoro --- src/arch/arm/aapcs32.hh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/arch/arm/aapcs32.hh b/src/arch/arm/aapcs32.hh index fd63483ef..e2e5d09f5 100644 --- a/src/arch/arm/aapcs32.hh +++ b/src/arch/arm/aapcs32.hh @@ -489,12 +489,12 @@ struct Argument(tc, state); - int index = state.allocate(Float{}, 1); + const int index = state.allocate(Float{}, 1); if (index >= 0) { constexpr int lane_per_reg = 16 / sizeof(Float); - constexpr int reg = index / lane_per_reg; - constexpr int lane = index % lane_per_reg; + const int reg = index / lane_per_reg; + const int lane = index % lane_per_reg; RegId id(VecRegClass, reg); auto val = tc->readVecReg(id); @@ -558,14 +558,14 @@ struct Argument(tc, state); - int base = state.allocate(Elem{}, Count); + const int base = state.allocate(Elem{}, Count); if (base >= 0) { constexpr int lane_per_reg = 16 / sizeof(Elem); HA ha; for (int i = 0; i < Count; i++) { - constexpr int index = base + i; - constexpr int reg = index / lane_per_reg; - constexpr int lane = index % lane_per_reg; + const int index = base + i; + const int reg = index / lane_per_reg; + const int lane = index % lane_per_reg; RegId id(VecRegClass, reg); auto val = tc->readVecReg(id); -- 2.30.2