LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Andi Kleen <andi@firstfloor.org>
Cc: Jeff Dike <jdike@addtoit.com>, Miklos Szeredi <miklos@szeredi.hu>,
	harvey.harrison@gmail.com, akpm@linux-foundation.org,
	linux-kernel@vger.kernel.org,
	user-mode-linux-devel@lists.sourceforge.net
Subject: Re: uml and -regparm=3
Date: Wed, 09 Jan 2008 18:45:53 -0800	[thread overview]
Message-ID: <478586E1.8010709@zytor.com> (raw)
In-Reply-To: <20080110023701.GB20813@one.firstfloor.org>

Andi Kleen wrote:
> On Wed, Jan 09, 2008 at 09:14:04PM -0500, Jeff Dike wrote:
>> On Wed, Jan 09, 2008 at 10:50:48PM +0100, Miklos Szeredi wrote:
>>>> FASTCALL is useless and should not make a difference. It enables
>>>> regparm on specific functions, but that should not make a difference
>>>> if it works or not.
>>> __down_write() in include/asm-x86/rwsem.h seems to assume, that the
>>> semaphore pointer is passed in %eax down to rwsem_down_write_failed(),
>>> so regparm does make a difference there.
>> And rwsem_down_write_failed seems to think it's getting the pointer in
>> %eax:
> 
> That's a left over from when it was called by magic inline assembly.
> I suspect it would be better to switch it just over to stack args
> for consistent and then declare it asmlinkage
> 

That seems to go in the wrong direction to me.  It would make more sense 
to gradually shift to asmlinkage actually being regparm=3.  This, of 
course, would require a different name (such as FASTCALL) until the 
conversion is complete -- even if done as a single patch series.

	-hpa

  reply	other threads:[~2008-01-10  2:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-09 21:01 Miklos Szeredi
2008-01-09 21:12 ` Andi Kleen
2008-01-09 21:20   ` Miklos Szeredi
2008-01-09 21:32     ` Andi Kleen
2008-01-09 21:50       ` Miklos Szeredi
2008-01-10  2:14         ` Jeff Dike
2008-01-10  2:37           ` Andi Kleen
2008-01-10  2:45             ` H. Peter Anvin [this message]
2008-01-09 21:33     ` Adrian Bunk
2008-01-09 22:01 ` linux-os (Dick Johnson)
2008-01-10  7:32 ` Ingo Molnar
2008-01-10  9:05   ` Miklos Szeredi
2008-01-10  9:35     ` Ingo Molnar

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=478586E1.8010709@zytor.com \
    --to=hpa@zytor.com \
    --cc=akpm@linux-foundation.org \
    --cc=andi@firstfloor.org \
    --cc=harvey.harrison@gmail.com \
    --cc=jdike@addtoit.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miklos@szeredi.hu \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    --subject='Re: uml and -regparm=3' \
    /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

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).