All of lore.kernel.org
 help / color / mirror / Atom feed
From: Russell King - ARM Linux admin <linux@armlinux.org.uk>
To: David Laight <David.Laight@ACULAB.COM>
Cc: 'Ard Biesheuvel' <ardb@kernel.org>, Antony Yu <swpenim@gmail.com>,
	Nicolas Pitre <nico@fluxnic.net>,
	Nick Desaulniers <ndesaulniers@google.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	clang-built-linux <clang-built-linux@googlegroups.com>,
	Nathan Chancellor <natechancellor@gmail.com>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>
Subject: Re: [RESEND,PATCH] ARM: fix __div64_32() error when compiling with clang
Date: Mon, 30 Nov 2020 14:18:04 +0000	[thread overview]
Message-ID: <20201130141804.GV1551@shell.armlinux.org.uk> (raw)
In-Reply-To: <ca83a5acdf514169b2fde3ec12ea59fd@AcuMS.aculab.com>

On Mon, Nov 30, 2020 at 01:58:27PM +0000, David Laight wrote:
> > And actually, the same applies on BE, but the other way around. So we
> > should mark __xl as an output register as well, as __xl will assume
> > the right value depending on the endianness.
> 
> Why not use "+r" to indicate than an 'output' parameter is also
> used as an input.
> 
> Rather cleaner than specifying the same C variable as both
> input and output.

You have an incorrect understanding. "__n" is the input operand in r0.
"__rem" is the output operand in r0/r1.

No single C variable is used as both an input and an output.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!

WARNING: multiple messages have this Message-ID (diff)
From: Russell King - ARM Linux admin <linux@armlinux.org.uk>
To: David Laight <David.Laight@ACULAB.COM>
Cc: Nicolas Pitre <nico@fluxnic.net>, Antony Yu <swpenim@gmail.com>,
	Nick Desaulniers <ndesaulniers@google.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	clang-built-linux <clang-built-linux@googlegroups.com>,
	Nathan Chancellor <natechancellor@gmail.com>,
	'Ard Biesheuvel' <ardb@kernel.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>
Subject: Re: [RESEND,PATCH] ARM: fix __div64_32() error when compiling with clang
Date: Mon, 30 Nov 2020 14:18:04 +0000	[thread overview]
Message-ID: <20201130141804.GV1551@shell.armlinux.org.uk> (raw)
In-Reply-To: <ca83a5acdf514169b2fde3ec12ea59fd@AcuMS.aculab.com>

On Mon, Nov 30, 2020 at 01:58:27PM +0000, David Laight wrote:
> > And actually, the same applies on BE, but the other way around. So we
> > should mark __xl as an output register as well, as __xl will assume
> > the right value depending on the endianness.
> 
> Why not use "+r" to indicate than an 'output' parameter is also
> used as an input.
> 
> Rather cleaner than specifying the same C variable as both
> input and output.

You have an incorrect understanding. "__n" is the input operand in r0.
"__rem" is the output operand in r0/r1.

No single C variable is used as both an input and an output.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-11-30 14:19 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-23  7:36 [RESEND,PATCH] ARM: fix __div64_32() error when compiling with clang Antony Yu
2020-11-23  7:36 ` Antony Yu
2020-11-23 18:16 ` Nathan Chancellor
2020-11-23 18:16   ` Nathan Chancellor
2020-11-24  7:42   ` Antony Yu
2020-11-24 10:14     ` Antony Yu
2020-11-24 10:14       ` [RESEND, PATCH] " Antony Yu
2020-11-24 21:06       ` [RESEND,PATCH] " Nick Desaulniers
2020-11-24 21:06         ` [RESEND, PATCH] " Nick Desaulniers
2020-11-30  8:20         ` [PATCH v2] " Antony Yu
2020-11-30  8:20           ` Antony Yu
2020-11-24 23:16 ` [RESEND,PATCH] " kernel test robot
2020-11-24 23:16   ` [RESEND, PATCH] " kernel test robot
2020-11-24 23:16   ` [RESEND,PATCH] " kernel test robot
2020-11-30 10:11 ` Ard Biesheuvel
2020-11-30 10:11   ` [RESEND, PATCH] " Ard Biesheuvel
2020-11-30 10:12   ` [RESEND,PATCH] " Ard Biesheuvel
2020-11-30 10:12     ` [RESEND, PATCH] " Ard Biesheuvel
2020-11-30 10:21     ` [RESEND,PATCH] " Russell King - ARM Linux admin
2020-11-30 10:21       ` Russell King - ARM Linux admin
2020-11-30 10:40       ` Ard Biesheuvel
2020-11-30 10:40         ` [RESEND, PATCH] " Ard Biesheuvel
2020-11-30 13:58         ` [RESEND,PATCH] " David Laight
2020-11-30 13:58           ` David Laight
2020-11-30 14:18           ` Russell King - ARM Linux admin [this message]
2020-11-30 14:18             ` Russell King - ARM Linux admin
2020-11-30 15:50     ` Nicolas Pitre
2020-11-30 15:50       ` Nicolas Pitre
2020-11-30 17:18       ` Ard Biesheuvel
2020-11-30 17:18         ` [RESEND, PATCH] " Ard Biesheuvel
2020-11-30 17:52         ` [RESEND,PATCH] " Nicolas Pitre
2020-11-30 17:52           ` Nicolas Pitre
2020-11-30 18:08           ` Ard Biesheuvel
2020-11-30 18:08             ` [RESEND, PATCH] " Ard Biesheuvel

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=20201130141804.GV1551@shell.armlinux.org.uk \
    --to=linux@armlinux.org.uk \
    --cc=David.Laight@ACULAB.COM \
    --cc=ardb@kernel.org \
    --cc=clang-built-linux@googlegroups.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=natechancellor@gmail.com \
    --cc=ndesaulniers@google.com \
    --cc=nico@fluxnic.net \
    --cc=swpenim@gmail.com \
    /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.