dev-arm: Correct cast of template parameter
authorAndrea Mondelli <Andrea.Mondelli@ucf.edu>
Thu, 14 Mar 2019 22:20:54 +0000 (18:20 -0400)
committerAndrea Mondelli <Andrea.Mondelli@ucf.edu>
Mon, 1 Apr 2019 15:55:58 +0000 (15:55 +0000)
commit283e092eda0b739a3c28bfa6293822e57ca67db6
treeba58ed333e5a365e76518aad47a2568d5409d070
parent2a98a994df296f818b05da90ba073d879562da04
dev-arm: Correct cast of template parameter

Clang with -Wconstant-conversion is _very_ restrictive on casting.
The shift operator results in an incorrect promotion.

This patch add a compile-time static cast that remove the error
when clang is used.

Change-Id: I3aa1e77da2565799feadc32317d5faa111b2de86
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17308
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
src/arch/arm/isa/insts/sve.isa
src/base/bitfield.hh