All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: Laurent Vivier <laurent@vivier.eu>, qemu-devel@nongnu.org
Cc: "Aurelien Jarno" <aurelien@aurel32.net>,
	"Philippe Mathieu-Daudé" <f4bug@amsat.org>
Subject: Re: [Qemu-devel] [PATCH v2 5/7] target/m68k: add fsglmul and fsgldiv
Date: Mon, 26 Jun 2017 15:57:54 -0700	[thread overview]
Message-ID: <379fda79-9fdf-7559-1b81-dbd8df0bbfe2@twiddle.net> (raw)
In-Reply-To: <20170626220330.6785-6-laurent@vivier.eu>

On 06/26/2017 03:03 PM, Laurent Vivier wrote:
> +void HELPER(fsglmul)(CPUM68KState *env, FPReg *res, FPReg *val0, FPReg *val1)
> +{
> +    floatx80 a, b;
> +
> +    PREC_BEGIN(32);
> +    a = floatx80_round(val0->d, &env->fp_status);
> +    b = floatx80_round(val1->d, &env->fp_status);
> +    res->d = floatx80_mul(a, b, &env->fp_status);
> +    PREC_END();
> +}
> +

You need to set the rounding mode to truncate for the first two operations.


r~

  reply	other threads:[~2017-06-26 22:58 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-26 22:03 [Qemu-devel] [PATCH v2 0/7] target/m68k: implement 680x0 FPU (part 2) Laurent Vivier
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 1/7] target/m68k: add fscc Laurent Vivier
2017-06-26 22:55   ` Richard Henderson
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 2/7] target/m68k: add fmovecr Laurent Vivier
2017-06-27 15:45   ` Philippe Mathieu-Daudé
2017-06-27 17:58     ` Laurent Vivier
2017-06-27 20:52       ` Philippe Mathieu-Daudé
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 3/7] target/m68k: add explicit single and double precision operations Laurent Vivier
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 4/7] softfloat: define floatx80_round() Laurent Vivier
2017-06-27 15:13   ` Laurent Vivier
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 5/7] target/m68k: add fsglmul and fsgldiv Laurent Vivier
2017-06-26 22:57   ` Richard Henderson [this message]
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 6/7] target/m68k: add explicit single and double precision operations (part 2) Laurent Vivier
2017-06-26 22:03 ` [Qemu-devel] [PATCH v2 7/7] target/m68k: add fmovem Laurent Vivier
2017-06-26 23:32   ` Richard Henderson

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=379fda79-9fdf-7559-1b81-dbd8df0bbfe2@twiddle.net \
    --to=rth@twiddle.net \
    --cc=aurelien@aurel32.net \
    --cc=f4bug@amsat.org \
    --cc=laurent@vivier.eu \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.