arch: Do value-initialization for MemOperand
authorGiacomo Travaglini <giacomo.travaglini@arm.com>
Mon, 9 Dec 2019 14:00:47 +0000 (14:00 +0000)
committerGiacomo Travaglini <giacomo.travaglini@arm.com>
Wed, 30 Sep 2020 08:50:39 +0000 (08:50 +0000)
commitd29349ead6384cdc1b28236ca3eeb1d79914a66f
tree7592cb22d421795a858221f87d33b382913e2d9a
parentba197c116368bbab05af6d636ab24cb65c73b291
arch: Do value-initialization for MemOperand

With this patch we are properly initializing the MemOperand
variable, with value-initialization.
Prior to this patch, the variable was simply default-initialized.
For a native type, this means the variable is undefined.
With value initialization we are sure the variable is not undefined
and the compiler doesn't complain about it.

JIRA: https://gem5.atlassian.net/browse/GEM5-196

Change-Id: I55a5b8f047b8e691529807b61d38f0d47fcfe61e
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23526
Tested-by: kokoro <noreply+kokoro@google.com>
Tested-by: Gem5 Cloud Project GCB service account <345032938727@cloudbuild.gserviceaccount.com>
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
src/arch/isa_parser.py