public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Willy Tarreau <w@1wt.eu>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	Ingo Molnar <mingo@kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Arjan van de Ven <arjan@infradead.org>
Subject: Re: [PATCH] x86-32: A better system call mechanism
Date: Sun, 1 Apr 2012 08:50:19 +0200	[thread overview]
Message-ID: <20120401065019.GA27590@1wt.eu> (raw)
In-Reply-To: <201204010000.quickdontsayit@terminus.zytor.com>

Hi Peter,

On Sun, Apr 01, 2012 at 12:00:00AM +0000, H. Peter Anvin wrote:
> On x86-32, we currently use int $0x80 as the primary system call
> mechanism.  Although there are some recent variants available on
> certain hardware (sysenter, syscall) via the vdso, the primary system
> call vector is still way up the interrupt vector table, which is
> inefficient.
> 
> This patch adds a very small amount of code which permits the very
> first vector to be used for system call.  That vector is #DE, divide
> error, generally known as division by zero.

Looks like a clever trick, but beyond the beauty, what does it really
save ? Code size is the same as aam 0 / div edx are both 2-byte long,
just like int 0x80. Is the call less expensive ? And if so, how does
it compare to vdso ?

Thanks,
Willy


  reply	other threads:[~2012-04-01  6:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-01  0:00 [PATCH] x86-32: A better system call mechanism H. Peter Anvin
2012-04-01  6:50 ` Willy Tarreau [this message]
2012-04-01  6:52   ` Willy Tarreau

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=20120401065019.GA27590@1wt.eu \
    --to=w@1wt.eu \
    --cc=arjan@infradead.org \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.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