aboutsummaryrefslogtreecommitdiff
path: root/ethosu/vela/fp_math.py
diff options
context:
space:
mode:
authorFredrik Svedberg <Fredrik.Svedberg@arm.com>2020-12-11 13:42:22 +0100
committerpatrik.gustavsson <patrik.gustavsson@arm.com>2020-12-18 12:16:19 +0000
commit5b513886ab120023eb1319d4883b175db8b7de3a (patch)
tree8ed296f6567daac9c1a564ad417f3d14ab1b7186 /ethosu/vela/fp_math.py
parent6c74c3bcaa733aa062c15d606726722b19c0dfdb (diff)
downloadethos-u-vela-5b513886ab120023eb1319d4883b175db8b7de3a.tar.gz
[MLBEDSW-297] Setup and run on Microsoft Windows
Various updates to make vela run and produce identical output on Microsoft Windows. * Fixed overflow errors * Fixed compile warnings * Avoid problematic numpy version * Updated README.md Signed-off-by: Fredrik Svedberg <Fredrik.Svedberg@arm.com> Change-Id: Ie48c63a92a00c81b3247d07f05b75d881319ddbb
Diffstat (limited to 'ethosu/vela/fp_math.py')
-rw-r--r--ethosu/vela/fp_math.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ethosu/vela/fp_math.py b/ethosu/vela/fp_math.py
index 66375611..5228f031 100644
--- a/ethosu/vela/fp_math.py
+++ b/ethosu/vela/fp_math.py
@@ -41,7 +41,7 @@ def saturating_rounding_mul(a, b):
if a == b and a == np.iinfo(np.int32).min:
return np.int32(np.iinfo(np.int32).max)
divider = 1 << 31
- ab = a * b
+ ab = np.int64(a) * np.int64(b)
if ab >= 0:
nudge = 1 << 30
return (ab + nudge) // divider