diff options
author | Tom Hughes <tomhughes@chromium.org> | 2021-09-29 23:00:48 +0000 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-10-07 17:17:11 +0000 |
commit | 1d4c8b3e2256225b944b03b6fda58743ac0d7b37 (patch) | |
tree | ec195da3d1a12ea97b225b5f5d89b4329882bb05 /core/minute-ia | |
parent | 71ac3fdc71a9a86fb77dd530e224552ac0aaf64f (diff) | |
download | chrome-ec-1d4c8b3e2256225b944b03b6fda58743ac0d7b37.tar.gz |
core/minute-ia: Fix inline asm in __isnanf
This function doesn't compile with clang:
core/minute-ia/include/fpu.h:207:10: error: unsupported inline asm:
input with type 'float' matching output with type 'uint16_t' (aka
'unsigned short')
: "0" (v));
^
Change the constraint "v" to match the __isinff function. According to
https://gcc.gnu.org/onlinedocs/gcc/Machine-Constraints.html#Machine-Constraints
"v" is "any EVEX encodable SSE register (%xmm0-%xmm31)"
As indicated by the TEST line, the output is identical before and after
this change.
BRANCH=none
BUG=b:172020503
TEST=./util/compare_build.sh -b all -j 70
=> MATCH
Signed-off-by: Tom Hughes <tomhughes@chromium.org>
Change-Id: Ia6db458fe4894d65af173c1e7dae34f3d675a4bc
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3194983
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Rong Chang <rongchang@chromium.org>
Diffstat (limited to 'core/minute-ia')
-rw-r--r-- | core/minute-ia/include/fpu.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/minute-ia/include/fpu.h b/core/minute-ia/include/fpu.h index fbcc7ae0f0..fb4865932e 100644 --- a/core/minute-ia/include/fpu.h +++ b/core/minute-ia/include/fpu.h @@ -204,7 +204,7 @@ static inline int __isnanf(float v) "fxam\n" "fnstsw %0\n" : "=r" (stat) - : "0" (v)); + : "v" (v)); return (stat & (COND_FP_NAN | COND_FP_NORMAL | COND_FP_ZERO)) == COND_FP_NAN; |