qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Joe Komlodi <joe.komlodi@xilinx.com>
To: qemu-devel@nongnu.org
Cc: edgar.iglesias@xilinx.com
Subject: [PATCH v1 1/1] target/microblaze: Fix FPU2 instruction check
Date: Mon, 11 May 2020 10:49:06 -0700	[thread overview]
Message-ID: <1589219346-106769-2-git-send-email-komlodi@xilinx.com> (raw)
In-Reply-To: <1589219346-106769-1-git-send-email-komlodi@xilinx.com>

The check to see if we can use FPU2 instructions would return 0 if
cfg.use_fpu == 2, rather than returning the PVR2_USE_FPU2_MASK.

This would cause all FPU2 instructions (fsqrt, flt, fint) to not be used.

Signed-off-by: Joe Komlodi <komlodi@xilinx.com>
---
 target/microblaze/translate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/target/microblaze/translate.c b/target/microblaze/translate.c
index 4e7f903a..329743b 100644
--- a/target/microblaze/translate.c
+++ b/target/microblaze/translate.c
@@ -1391,7 +1391,7 @@ static int dec_check_fpuv2(DisasContext *dc)
         tcg_gen_movi_i64(cpu_SR[SR_ESR], ESR_EC_FPU);
         t_gen_raise_exception(dc, EXCP_HW_EXCP);
     }
-    return (dc->cpu->cfg.use_fpu == 2) ? 0 : PVR2_USE_FPU2_MASK;
+    return (dc->cpu->cfg.use_fpu == 2) ? PVR2_USE_FPU2_MASK : 0;
 }
 
 static void dec_fpu(DisasContext *dc)
-- 
2.7.4



  reply	other threads:[~2020-05-11 17:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-11 17:49 [PATCH v1 0/1] target/microblaze: Fix FPU2 instruction check Joe Komlodi
2020-05-11 17:49 ` Joe Komlodi [this message]
2020-05-13 11:46 ` Edgar E. Iglesias

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=1589219346-106769-2-git-send-email-komlodi@xilinx.com \
    --to=joe.komlodi@xilinx.com \
    --cc=edgar.iglesias@xilinx.com \
    --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).