From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>
Subject: [PATCH 5/7] tcg/tcg-op: Document wswap() byte pattern
Date: Tue, 22 Aug 2023 11:37:10 +0200 [thread overview]
Message-ID: <20230822093712.38922-6-philmd@linaro.org> (raw)
In-Reply-To: <20230822093712.38922-1-philmd@linaro.org>
Document wswap_i64(), added in commit 46be8425ff
("tcg: Implement tcg_gen_{h,w}swap_{i32,i64}").
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
docs/devel/tcg-ops.rst | 4 ++++
tcg/tcg-op.c | 5 +++++
2 files changed, 9 insertions(+)
diff --git a/docs/devel/tcg-ops.rst b/docs/devel/tcg-ops.rst
index d9364effd2..306025ece7 100644
--- a/docs/devel/tcg-ops.rst
+++ b/docs/devel/tcg-ops.rst
@@ -490,6 +490,10 @@ Misc
- | Swap 16-bit halfwords within a 32/64-bit value.
+ * - wswap_i64 *t0*, *t1*
+
+ - | Swap 32-bit words within a 64-bit value.
+
Conditional moves
-----------------
diff --git a/tcg/tcg-op.c b/tcg/tcg-op.c
index bb64326a1a..c436c5e263 100644
--- a/tcg/tcg-op.c
+++ b/tcg/tcg-op.c
@@ -1908,6 +1908,11 @@ void tcg_gen_hswap_i64(TCGv_i64 ret, TCGv_i64 arg)
tcg_temp_free_i64(t1);
}
+/*
+ * wswap_i64: Swap 32-bit words within a 64-bit value.
+ *
+ * Byte pattern: wswap_i64(abcdefgh) -> efghabcd
+ */
void tcg_gen_wswap_i64(TCGv_i64 ret, TCGv_i64 arg)
{
/* Swapping 2 32-bit elements is a rotate. */
--
2.41.0
next prev parent reply other threads:[~2023-08-22 9:38 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-22 9:37 [PATCH 0/7] tcg: Document *swap/deposit helpers Philippe Mathieu-Daudé
2023-08-22 9:37 ` [PATCH 1/7] tcg/tcg-op: Document bswap16() byte pattern Philippe Mathieu-Daudé
2023-08-22 15:58 ` Richard Henderson
2023-08-22 17:22 ` Philippe Mathieu-Daudé
2023-08-22 17:29 ` Richard Henderson
2023-08-22 22:04 ` Philippe Mathieu-Daudé
2023-08-22 9:37 ` [PATCH 2/7] tcg/tcg-op: Document bswap32() " Philippe Mathieu-Daudé
2023-08-22 16:00 ` Richard Henderson
2023-08-23 13:14 ` Philippe Mathieu-Daudé
2023-08-23 15:54 ` Richard Henderson
2023-08-22 9:37 ` [PATCH 3/7] tcg/tcg-op: Document bswap64() " Philippe Mathieu-Daudé
2023-08-22 16:00 ` Richard Henderson
2023-08-22 9:37 ` [PATCH 4/7] tcg/tcg-op: Document hswap() " Philippe Mathieu-Daudé
2023-08-22 16:02 ` Richard Henderson
2023-08-22 16:04 ` Richard Henderson
2023-08-22 9:37 ` Philippe Mathieu-Daudé [this message]
2023-08-22 16:03 ` [PATCH 5/7] tcg/tcg-op: Document wswap() " Richard Henderson
2023-08-22 9:37 ` [PATCH 6/7] tcg/tcg-op: Document deposit_z() Philippe Mathieu-Daudé
2023-08-22 16:05 ` Richard Henderson
2023-08-22 9:37 ` [PATCH 7/7] target/cris: Fix a typo in gen_swapr() Philippe Mathieu-Daudé
2023-08-22 13:42 ` [PATCH 0/7] tcg: Document *swap/deposit helpers Alex Bennée
2023-08-22 13:58 ` Peter Maydell
2023-08-22 14:43 ` Philippe Mathieu-Daudé
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=20230822093712.38922-6-philmd@linaro.org \
--to=philmd@linaro.org \
--cc=edgar.iglesias@gmail.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
/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).