python: Remove a call to reduce() from code_formatter.py.
authorGabe Black <gabeblack@google.com>
Tue, 13 Oct 2020 12:00:37 +0000 (05:00 -0700)
committerGabe Black <gabeblack@google.com>
Wed, 14 Oct 2020 00:03:07 +0000 (00:03 +0000)
commitb3e8097f34ffab278ea87ed3e64e6470044ec978
tree4599e52d0d801144a582035b26b4a1b7b8e03fa5
parentdf6269b63425d98a1c4ef289b41a09772b67d6f2
python: Remove a call to reduce() from code_formatter.py.

The built in reduce method is no longer available in python 3. Besides
that, this particular bit of code is simpler and easier to read if
reduce is replaced with the also built in sum() method.

Change-Id: I6daca42494ea0534721dfcfb1f6058517cd482d9
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35941
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
src/python/m5/util/code_formatter.py