Commit 8f9c6ff5 authored by Kir Kolyshkin's avatar Kir Kolyshkin Committed by Pavel Emelyanov

fpu00 test: fix for clang

clang complains a number of times on our inline asm code, like this:

> fpu00.c:13:6: error: ambiguous instructions require an explicit suffix
> (could be 'flds', 'fldl', or 'fldt')
>                           "fld  %0\n"
>                           ^
> <inline asm>:1:2: note: instantiated into assembly here
>         fld     -4(%rsp)
>         ^

As floats are used, the suffix should be 's' ("short", 32-bit, float).

Add it where needed.
Signed-off-by: 's avatarKir Kolyshkin <kir@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent a95939c0
...@@ -10,10 +10,10 @@ const char *test_author = "Pavel Emelianov <xemul@parallels.com>"; ...@@ -10,10 +10,10 @@ const char *test_author = "Pavel Emelianov <xemul@parallels.com>";
void start(float a, float b, float c, float d) void start(float a, float b, float c, float d)
{ {
__asm__ volatile ( __asm__ volatile (
"fld %0\n" "flds %0\n"
"fadd %1\n" "fadds %1\n"
"fld %2\n" "flds %2\n"
"fadd %3\n" "fadds %3\n"
"fmulp %%st(1)\n" "fmulp %%st(1)\n"
: :
: "m" (a), "m" (b), "m" (c), "m" (d) : "m" (a), "m" (b), "m" (c), "m" (d)
...@@ -25,7 +25,7 @@ float finish(void) ...@@ -25,7 +25,7 @@ float finish(void)
float res; float res;
__asm__ volatile ( __asm__ volatile (
"fstp %0\n" "fstps %0\n"
: "=m" (res) : "=m" (res)
); );
return res; return res;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment