From: Chun-Chen Hsu Date: Tue, 13 Mar 2018 10:24:21 +0000 (+0800) Subject: arm: Fix maybe-uninitialized GCC warnings X-Git-Tag: v19.0.0.0~2236 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9f8491ecbfb80696b62a5a878fe40f81a8a0d35c;p=gem5.git arm: Fix maybe-uninitialized GCC warnings GCC 7 generates maybe-uninitialized warnings at the code that updates the "dest" variables in the writeVecElem function of neon64_mem.hh file. It is because the generated code does not appropriately initialize the output variable before passing it to the writeVecElem function. This patch initializes the output variable to fix this. Change-Id: I50a8f4e456ccdcaa3db1392ec097017450c56ecb Signed-off-by: Chun-Chen Hsu Reviewed-on: https://gem5-review.googlesource.com/9121 Reviewed-by: Jason Lowe-Power Reviewed-by: Andreas Sandberg Maintainer: Andreas Sandberg --- diff --git a/src/arch/arm/isa/insts/neon64_mem.isa b/src/arch/arm/isa/insts/neon64_mem.isa index 4d3241226..4511ad105 100644 --- a/src/arch/arm/isa/insts/neon64_mem.isa +++ b/src/arch/arm/isa/insts/neon64_mem.isa @@ -336,7 +336,8 @@ let {{ eCode = ''' //input data from scratch area VReg input[4] = { {0, 0}, {0, 0}, {0, 0}, {0, 0} }; - VReg output[2]; //output data to arch. SIMD regs + //output data to arch. SIMD regs + VReg output[2] = { {0, 0}, {0, 0} }; ''' eCode += getInputCodeOp1L