mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: john stultz <johnstul@us.ibm.com>
To: lkml <linux-kernel@vger.kernel.org>
Cc: Andrea Arcangeli <andrea@suse.de>, Andi Kleen <ak@suse.de>,
	Ulrich Drepper <drepper@redhat.com>,
	Jamie Lokier <jamie@shareable.org>,
	"Martin J. Bligh" <mbligh@aracnet.com>,
	Wim Coekaerts <wim.coekaerts@oracle.com>,
	Joel Becker <Joel.Becker@oracle.com>,
	Chris McDermott <lcm@us.ibm.com>
Subject: [RFC][PATCH] vsyscall-gtod_B3 (0/3)
Date: Wed, 03 Mar 2004 16:11:22 -0800	[thread overview]
Message-ID: <1078359081.10076.191.camel@cog.beaverton.ibm.com> (raw)

All,
	This is my port of the x86-64 vsyscall gettimeofday code to i386. This
patch moves gettimeofday into userspace, so it can be calledwithout the
syscall overhead, greatly improving performance. This is important for
any application, like a database, which heavily uses gettimeofday for
time-stamping. It supports both the TSC and IBM x44X cyclone time
source.
	
Example performance gain (using cyclone timesource):

int80 gettimeofday:
gettimeofday ( 1665576us / 1000000runs ) = 1.665574us

systenter gettimeofday:
gettimeofday ( 1239215us / 1000000runs ) = 1.239214us

vsyscall gettimeofday:
gettimeofday ( 875876us / 1000000runs ) = 0.875875us


I've broken the patch into three logical chuncks for clarity and to make
it easier to cherry pick the desired bits. 

o Part 1: Renames variables in timer_cyclone.c and timer_tsc.c to avoid
conflicts in the global namespace.
o Part 2: Core vsyscall-gtod implementation. 
o Part 3: vDSO hooks to avoid LD_PRELOADing or needing changes to glibc

Please let me know if you have any comments or suggestions.

thanks
-john

Existing issues:
----------------
o Bad pointers cause segfaults, rather then -EFAULT.

Release History:
----------------
B2 -> B3:
o Broke the patch up into 3 chunks
o Added vsyscall-int80.S hooks (4G disables SEP)

B1 -> B2:
o No LD_PRELOADing or changes to userspace required!
o removed hard-coded address in linker script

B0 -> B1:
o Cleaned up 4/4 split code, so no additional patch is needed.
o Fixed permissions on fixmapped cyclone pageo Improved
alternate_instruction workaround 
o Use NTP variables to avoid related time inconsistencieso minor code
cleanups


             reply	other threads:[~2004-03-04  0:11 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-04  0:11 john stultz [this message]
2004-03-04  0:12 ` [RFC][PATCH] linux-2.6.4-pre1_vsyscall-gtod_B3-part1 (1/3) john stultz
2004-03-04  0:13   ` [RFC][PATCH] linux-2.6.4-pre1_vsyscall-gtod_B3-part2 (2/3) john stultz
2004-03-04  0:14     ` [RFC][PATCH] linux-2.6.4-pre1_vsyscall-gtod_B3-part3 (3/3) john stultz
2004-03-04  0:55       ` Andrea Arcangeli
2004-03-04  2:16         ` Ulrich Drepper
2004-03-04  2:43           ` john stultz
2004-03-04  3:14             ` Andrea Arcangeli
2004-03-04  8:09             ` Ulrich Drepper
2004-03-04 19:02               ` john stultz
2004-03-04  2:47           ` Andrea Arcangeli
2004-03-04  2:54             ` john stultz
2004-03-04  3:15               ` Andrea Arcangeli
2004-03-04  8:57               ` Jakub Jelinek
2004-03-04 16:45                 ` Andrea Arcangeli
2004-03-04  8:00         ` Jamie Lokier
2004-03-04  8:37           ` Jakub Jelinek
2004-03-04 17:48             ` Andrea Arcangeli
2004-03-04  0:15 ` [RFC] vsyscall-gtod_test_B3.tar.gz john stultz

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=1078359081.10076.191.camel@cog.beaverton.ibm.com \
    --to=johnstul@us.ibm.com \
    --cc=Joel.Becker@oracle.com \
    --cc=ak@suse.de \
    --cc=andrea@suse.de \
    --cc=drepper@redhat.com \
    --cc=jamie@shareable.org \
    --cc=lcm@us.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mbligh@aracnet.com \
    --cc=wim.coekaerts@oracle.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®