public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: "Chen, Kenneth W" <kenneth.w.chen@intel.com>
To: linux-ia64@vger.kernel.org
Subject: RE: [PATCH] SN2 user-MMIO CPU migration
Date: Wed, 25 Jan 2006 00:29:31 +0000	[thread overview]
Message-ID: <200601250029.k0P0TVg16877@unix-os.sc.intel.com> (raw)
In-Reply-To: <20060118163305.Y42462@chenjesu.americas.sgi.com>

Brent Casavant wrote on Tuesday, January 24, 2006 3:55 PM
> > > Regarding the direction Ingo sent me down, and considering what Jack
> > > said about needing a hook for a future platform, I'm thinking of grabbing
> > > a bit in task->thread.flags that IA64_HAS_EXTRA_STATE() could detect and
> > > let ia64_{save,load}_extra() call new machvecs to perform this
> > > chipset-specific context management.  It's a bit overengineered for
> > > my particular case, but would allow Jack to plug in his work very
> > > cleanly.
> > 
> > I wonder why you did not continue on this path.
> 
> Two main reasons:
> 
> 1. Requires an arch hook in the main scheduler to set the flag in most
>    places set_task_cpu() is called.  Ingo didn't seem fond of that
>    (see my original patch and his response).
> 2. The initialization code gets kind of ugly.
> 

Well, maybe bad wording, I didn't meant to pursue scheduler hook in the
generic code.  Instead, idea is morphed into having a thread specific
bit to tell kernel whether it needs to do MMIO synchronization for that
task at context switch.  The beauty of it is that for task that doesn't
need to do any of MMIO synchronization, the cost is kept at minimal even
if task migrated.

In the event of task migration, your "take 4" patch will cause a cache
line update, another cache line read for the function pointer, followed
by an empty function call, on *all* non-sn2 platforms.  Even on sn2
platform, for process that *doesn't* do MMIO, you are still paying the
cost of accessing shub in sn_migrate(), which can be optimized away. I
hope you understand what I'm talking about.  Otherwise, I can do a patch
on top of yours.

- Ken


  parent reply	other threads:[~2006-01-25  0:29 UTC|newest]

Thread overview: 73+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-20  0:06 [PATCH] SN2 user-MMIO CPU migration Brent Casavant
2006-01-20  2:18 ` Jesse Barnes
2006-01-20  6:47   ` Brent Casavant
2006-01-20 17:36     ` Jesse Barnes
2006-01-20 20:01       ` Brent Casavant
2006-01-20 13:26   ` Jack Steiner
2006-01-20 17:31     ` Jesse Barnes
2006-01-20 19:00       ` Jack Steiner
2006-01-20  8:36 ` Ingo Molnar
2006-01-20 16:14   ` Brent Casavant
2006-01-24  0:33 ` Brent Casavant
2006-01-24  0:48 ` Luck, Tony
2006-01-24  1:23 ` Brent Casavant
2006-01-24  1:42 ` Keith Owens
2006-01-24  3:41 ` Grant Grundler
2006-01-24  6:30 ` Brent Casavant
2006-01-24  6:41 ` Brent Casavant
2006-01-24  7:04 ` Grant Grundler
2006-01-24  9:02 ` Ingo Molnar
2006-01-24  9:14 ` Jes Sorensen
2006-01-24 12:10 ` Robin Holt
2006-01-24 16:40 ` Grant Grundler
2006-01-24 16:52 ` Brent Casavant
2006-01-24 16:57 ` Brent Casavant
2006-01-24 17:00 ` Robin Holt
2006-01-24 17:33 ` Luck, Tony
2006-01-24 18:42 ` Grant Grundler
2006-01-24 21:12 ` Brent Casavant
2006-01-24 21:41 ` Ingo Molnar
2006-01-24 21:43 ` Chen, Kenneth W
2006-01-24 21:51 ` Luck, Tony
2006-01-24 22:04 ` Brent Casavant
2006-01-24 22:07 ` Chen, Kenneth W
2006-01-24 22:12 ` Brent Casavant
2006-01-24 22:19 ` Chen, Kenneth W
2006-01-24 22:31 ` Chen, Kenneth W
2006-01-24 22:41 ` Brent Casavant
2006-01-24 23:25 ` Chen, Kenneth W
2006-01-24 23:28 ` Brent Casavant
2006-01-24 23:36 ` Chen, Kenneth W
2006-01-24 23:54 ` Brent Casavant
2006-01-25  0:10 ` Brent Casavant
2006-01-25  0:29 ` Chen, Kenneth W [this message]
2006-01-25  6:27 ` Keith Owens
2006-01-25  9:04 ` Chen, Kenneth W
2006-01-25  9:24 ` Chen, Kenneth W
2006-01-25 17:04 ` Brent Casavant
2006-01-25 17:45 ` Brent Casavant
2006-01-25 17:48 ` Brent Casavant
2006-01-25 19:01 ` Chen, Kenneth W
2006-01-25 19:15 ` Brent Casavant
2006-01-25 19:43 ` Jack Steiner
2006-01-25 22:49 ` Brent Casavant
2006-01-25 23:09 ` Brent Casavant
2006-01-25 23:49 ` Brent Casavant
2006-01-25 23:56 ` Chen, Kenneth W
2006-01-26  1:06 ` Luck, Tony
2006-01-26  1:31 ` Prarit Bhargava
2006-01-26  2:43 ` Keith Owens
2006-01-26  4:40 ` Brent Casavant
2006-01-26 16:29 ` Brent Casavant
2006-01-26 16:41 ` Prarit Bhargava
2006-01-26 19:29 ` Brent Casavant
2006-01-26 19:54 ` Luck, Tony
2006-01-26 20:28 ` Brent Casavant
2006-01-26 21:05 ` Luck, Tony
2006-01-26 21:34 ` Prarit Bhargava
2006-01-26 22:11 ` Luck, Tony
2006-01-26 23:08 ` Luck, Tony
2006-01-26 23:21 ` Prarit Bhargava
2006-01-26 23:44 ` Prarit Bhargava
2006-01-27  0:07 ` Chen, Kenneth W
2006-01-27 14:01 ` Prarit Bhargava

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=200601250029.k0P0TVg16877@unix-os.sc.intel.com \
    --to=kenneth.w.chen@intel.com \
    --cc=linux-ia64@vger.kernel.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