qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <richard.henderson@linaro.org>
To: qemu-devel@nongnu.org
Subject: [PATCH RISU] risugen/arm: Refine prefetch and memory hintspace patterns
Date: Wed, 29 May 2024 10:36:25 -0700	[thread overview]
Message-ID: <20240529173625.800102-1-richard.henderson@linaro.org> (raw)

Avoid prefetch patterns that are UNPREDICTABLE.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
 thumb.risu | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/thumb.risu b/thumb.risu
index 357b791..6a05bf2 100644
--- a/thumb.risu
+++ b/thumb.risu
@@ -33,7 +33,20 @@ SMMUL T1 11111 0110 101 rn:4 1111 rd:4 000 r rm:4
 # preload and memory hint space (in the byte and halfword
 # load space, where Rt == 15).
 # The constraint is to avoid UNPREDICTABLE space
-HINTSPACE T1 111 1100 op1:2 0 z 1 y:4 1111 op2:6 any:6 { ($y == 15) || (($op1 & 1) != 0) || !((($op2 & 0x24) == 0x24) || (($op2 & 0x3c) == 0x38)) ; }
+PLD_pi        TI 1111 1000 10 w 1 rn:4 1111 imm:12            { $rn != 0xf; }
+PLD_ni        TI 1111 1000 00 w 1 rn:4 1111 1100 imm:8        { $rn != 0xf; }
+PLD_li        TI 1111 1000 u 00 1 1111 1111 imm:12
+PLD_rr        TI 1111 1000 00 w 1 rn:4 1111 000000 imm:2 rm:4 \
+              { $rn != 0xf && $rm != 0xf; }
+PLI_pi        TI 1111 1001 1 00 1 rn:4 1111 imm:12            { $rn != 0xf; }
+PLI_ni        TI 1111 1001 0 00 1 rn:4 1111 1100 imm:8        { $rn != 0xf; }
+PLI_li        TI 1111 1001 u 00 1 1111 1111 imm:12
+PLI_rr        TI 1111 1001 0 00 1 rn:4 1111 000000 imm:2 rm:4 \
+              { $rn != 0xf && $rm != 0xf; }
+HINTSPACE_rr  T1 1111 1001 0011 rn:4 1111 000000 imm:2 rm:4   { $rn != 0xf; }
+HINTSPACE_ni  T1 1111 1001 0011 rn:4 1111 1100 imm:8          { $rn != 0xf; }
+HINTSPACE_pi  T1 1111 1001 1011 rn:4 1111 imm:12              { $rn != 0xf; }
+HINTSPACE_li  T1 1111 1001 u 011 1111 1111 imm:12
 
 # VMLAL, VMLSL, VQDMLAL, VQDMLSL, VMULL, VQDMULL
 # NB that enc T1 is actually VMLA/VMLS only, T2 is VMLAL/VMLSL only
-- 
2.34.1



             reply	other threads:[~2024-05-29 17:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-29 17:36 Richard Henderson [this message]
2024-05-30 13:33 ` [PATCH RISU] risugen/arm: Refine prefetch and memory hintspace patterns Peter Maydell

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=20240529173625.800102-1-richard.henderson@linaro.org \
    --to=richard.henderson@linaro.org \
    --cc=qemu-devel@nongnu.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).