From: malc <av1474@comtv.ru>
To: Richard Henderson <rth@twiddle.net>
Cc: Laurent Desnogues <laurent.desnogues@gmail.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 1/6] tcg: Generic support for conditional set and conditional move.
Date: Thu, 17 Dec 2009 23:50:10 +0300 (MSK) [thread overview]
Message-ID: <Pine.LNX.4.64.0912172348150.4775@linmac.oyster.ru> (raw)
In-Reply-To: <d6c09704ab7b9b1fb303d08f817b1499f3e49439.1261078375.git.rth@twiddle.net>
On Thu, 17 Dec 2009, Richard Henderson wrote:
> Defines setcond and movcond for implementing conditional moves at
> the tcg opcode level. 64-bit-on-32-bit is expanded via a setcond2
> primitive plus other operations.
>
> Signed-off-by: Richard Henderson <rth@twiddle.net>
> ---
> tcg/README | 26 +++++++++++++++-
> tcg/tcg-op.h | 91 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> tcg/tcg-opc.h | 5 +++
> tcg/tcg.c | 23 ++++++++++----
> 4 files changed, 138 insertions(+), 7 deletions(-)
>
> diff --git a/tcg/README b/tcg/README
> index e672258..8617994 100644
> --- a/tcg/README
> +++ b/tcg/README
> @@ -152,6 +152,11 @@ Conditional jump if t0 cond t1 is true. cond can be:
> TCG_COND_LEU /* unsigned */
> TCG_COND_GTU /* unsigned */
>
> +* brcond2_i32 cond, t0_low, t0_high, t1_low, t1_high, label
> +
> +Similar to brcond, except that the 64-bit values T0 and T1
> +are formed from two 32-bit arguments.
> +
> ********* Arithmetic
>
> * add_i32/i64 t0, t1, t2
> @@ -282,6 +287,25 @@ order bytes must be set to zero.
> Indicate that the value of t0 won't be used later. It is useful to
> force dead code elimination.
>
> +********* Conditional moves
> +
> +* setcond_i32/i64 cond, dest, t1, t2
> +
> +dest = (t1 cond t2)
> +
> +Set DEST to 1 if (T1 cond T2) is true, otherwise set to 0.
> +
> +* movcond_i32/i64 cond, dest, c1, c2, vtrue, vfalse
> +
> +dest= (c1 cond c2 ? vtrue : of)
Nitpick: no space before '='
> +
> +Set DEST to VTRUE if (c1 cond c2) is true, otherwise set to VFALSE.
But it reads `? vtrue : of'. Should probably be `? vtrue : vfalse`
[..snip..]
--
mailto:av1474@comtv.ru
next prev parent reply other threads:[~2009-12-17 20:50 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <761ea48b0912170620l534dcb02m8ea6b59524d76dbe@mail.gmail.com>
2009-12-17 19:32 ` [Qemu-devel] [PATCH 0/6] tcg conditional set/move, round 2 Richard Henderson
2009-12-17 17:27 ` [Qemu-devel] [PATCH 1/6] tcg: Generic support for conditional set and conditional move Richard Henderson
2009-12-17 20:50 ` malc [this message]
2009-12-18 11:38 ` [Qemu-devel] " Laurent Desnogues
2009-12-17 17:28 ` [Qemu-devel] [PATCH 2/6] tcg: Add tcg_invert_cond Richard Henderson
2009-12-18 11:39 ` [Qemu-devel] " Laurent Desnogues
2009-12-17 17:32 ` [Qemu-devel] [PATCH 3/6] tcg-x86_64: Implement setcond and movcond Richard Henderson
2009-12-18 11:39 ` [Qemu-devel] " Laurent Desnogues
2009-12-18 17:11 ` Richard Henderson
2009-12-18 17:41 ` Laurent Desnogues
2009-12-17 17:55 ` [Qemu-devel] [PATCH 4/6] tcg-i386: Implement small forward branches Richard Henderson
2009-12-18 11:39 ` [Qemu-devel] " Laurent Desnogues
2009-12-18 17:16 ` Richard Henderson
2009-12-17 18:38 ` [Qemu-devel] [PATCH 5/6] tcg-i386: Simplify brcond2 Richard Henderson
2009-12-18 11:40 ` [Qemu-devel] " Laurent Desnogues
2009-12-18 17:45 ` Richard Henderson
2009-12-17 19:08 ` [Qemu-devel] [PATCH 6/6] tcg-i386: Implement setcond, movcond, setcond2 Richard Henderson
2009-12-18 11:37 ` [Qemu-devel] Re: [PATCH 0/6] tcg conditional set/move, round 2 Laurent Desnogues
2009-12-18 21:38 ` [Qemu-devel] tcg conditional set/move, round 3 Richard Henderson
2009-12-19 11:40 ` [Qemu-devel] " Laurent Desnogues
2009-12-19 16:09 ` Richard Henderson
2009-12-19 12:09 ` [Qemu-devel] " Andreas Färber
2009-12-19 13:03 ` Aurelien Jarno
2009-12-19 13:32 ` Aurelien Jarno
2009-12-19 16:19 ` Richard Henderson
2009-12-19 23:02 ` Aurelien Jarno
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.64.0912172348150.4775@linmac.oyster.ru \
--to=av1474@comtv.ru \
--cc=laurent.desnogues@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).