All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>,
	David Gibson <david@gibson.dropbear.id.au>
Cc: qemu-ppc@nongnu.org, qemu-devel@nongnu.org,
	aneesh.kumar@linux.vnet.ibm.com
Subject: Re: [Qemu-devel] [RFC 5/6] target-ppc: add modulo word operations
Date: Thu, 21 Jul 2016 11:54:39 +0530	[thread overview]
Message-ID: <e9238111-abe3-b540-1913-dc05b11fe2ba@twiddle.net> (raw)
In-Reply-To: <87fur7pm7e.fsf@abhimanyu.i-did-not-set--mail-host-address--so-tickle-me>

On 07/18/2016 10:38 AM, Nikunj A Dadhania wrote:
> David Gibson <david@gibson.dropbear.id.au> writes:
>
>> [ Unknown signature status ]
>> On Tue, Jul 12, 2016 at 11:33:21PM +0530, Nikunj A Dadhania wrote:
>>> Adding following instructions:
>>>
>>> moduw: Modulo Unsigned Word
>>> modsw: Modulo Signed Word
>>>
>>> Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
>>
>> Hrm.. any reason you're not using the TCG inbuilt remainder ops
>> (tcg_gen_rem_i32() etc.)?
>
> I have an updated version with me which uses inbuilt ops, i was searching
> for modulo expressions, which I didn't find, so wrote. Found later that
> it is called tcg_gen_rem. Will send in the next version.

It would probably be better to use helper functions for both div and mod, 
because of the branches required.

C.f. target-arm/helper-a64.c, helper_sdiv64 et al.


r~

  reply	other threads:[~2016-07-21  6:24 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-12 18:03 [Qemu-devel] [RFC 0/6] POWER9 TCG enablements - part1 Nikunj A Dadhania
2016-07-12 18:03 ` [Qemu-devel] [RFC 1/6] target-ppc: Introduce Power9 family Nikunj A Dadhania
2016-07-14  5:26   ` Bharata B Rao
2016-07-14  6:02     ` Nikunj A Dadhania
2016-07-18  1:48   ` David Gibson
2016-07-18  5:13     ` Nikunj A Dadhania
2016-07-12 18:03 ` [Qemu-devel] [RFC 2/6] target-ppc: Introduce POWER ISA 3.0 flag Nikunj A Dadhania
2016-07-18  1:49   ` David Gibson
2016-07-12 18:03 ` [Qemu-devel] [RFC 3/6] target-ppc: adding addpcis instruction Nikunj A Dadhania
2016-07-18  1:55   ` David Gibson
2016-07-21  5:59   ` Richard Henderson
2016-07-21  8:06     ` Nikunj A Dadhania
2016-07-12 18:03 ` [Qemu-devel] [RFC 4/6] target-ppc: add cmprb instruction Nikunj A Dadhania
2016-07-18  2:00   ` David Gibson
2016-07-21  6:17   ` Richard Henderson
2016-07-21  8:08     ` Nikunj A Dadhania
2016-08-02  7:02     ` Nikunj A Dadhania
2016-07-12 18:03 ` [Qemu-devel] [RFC 5/6] target-ppc: add modulo word operations Nikunj A Dadhania
2016-07-18  2:04   ` David Gibson
2016-07-18  5:08     ` Nikunj A Dadhania
2016-07-21  6:24       ` Richard Henderson [this message]
2016-07-21  8:11         ` Nikunj A Dadhania
2016-07-21 10:24           ` Richard Henderson
2016-07-12 18:03 ` [Qemu-devel] [RFC 6/6] target-ppc: add modulo dword operations Nikunj A Dadhania

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=e9238111-abe3-b540-1913-dc05b11fe2ba@twiddle.net \
    --to=rth@twiddle.net \
    --cc=aneesh.kumar@linux.vnet.ibm.com \
    --cc=david@gibson.dropbear.id.au \
    --cc=nikunj@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@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.