[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 3/3] tests/tcg/s390x: test signed vfmin/vfmax
From: |
Richard Henderson |
Subject: |
Re: [PATCH 3/3] tests/tcg/s390x: test signed vfmin/vfmax |
Date: |
Wed, 13 Jul 2022 21:14:44 +0530 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 |
On 7/12/22 18:02, Ilya Leoshkevich wrote:
This works, of course. It could be simpler using EXECUTE, to store
just the one
instruction and not worry about an executable mapped page, but I
guess it doesn't matter.
I thought about this too, but EX/EXRL operate only on the second byte,
and I need to modify bytes 3-5 here.
I didn't mean modify the instruction via EX, but something like
static char minmax[6] __attribute__((aligned(2)))
= { xx, yy, zz, 0, 0, 0 };
minmax[3] = m6 ...
minmax[4] = ...
minmax[5] = op;
asm("vl %%v25,0(%1)\n"
"vl %%v26,0(%2)\n"
"ex 0,0(%3)\n"
"vst %%v24,0(%0)"
: : "a"(v1), "a"(v2), "a"(v3), "a"(minmax)
: "memory", "v24", "v25", "v26);
r~