From: Arjan van de Ven <arjan@infradead.org>
To: Andi Kleen <ak@suse.de>
Cc: eranian@hpl.hp.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] x86-64 TIF flags for debug regs and io bitmap in ctxsw
Date: Tue, 04 Jul 2006 10:22:16 +0200 [thread overview]
Message-ID: <1152001336.3109.10.camel@laptopd505.fenrus.org> (raw)
In-Reply-To: <200607041009.31588.ak@suse.de>
On Tue, 2006-07-04 at 10:09 +0200, Andi Kleen wrote:
> On Tuesday 04 July 2006 09:51, Arjan van de Ven wrote:
> > > - }
> > > - }
> > > + if (unlikely((task_thread_info(next_p)->flags & _TIF_WORK_CTXSW))
> > > + || test_tsk_thread_flag(prev_p, TIF_IO_BITMAP))
> > > + __switch_to_xtra(prev_p, next_p, tss);
> >
> > well isn't this replacing an if() (which isn't cheap but also not
> > expensive, due to unlikely()) with an atomic operation (which *is*
> > expensive) ?
>
> Where do you see an atomic operation?
test_tsk_thread_flag() ends up doing an atomic op afaics
next prev parent reply other threads:[~2006-07-04 8:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-04 7:28 Stephane Eranian
2006-07-04 7:51 ` Arjan van de Ven
2006-07-04 8:09 ` Andi Kleen
2006-07-04 8:22 ` Arjan van de Ven [this message]
2006-07-04 8:10 ` Stephane Eranian
2006-07-04 8:14 ` Stephane Eranian
2006-07-04 8:14 ` Andi Kleen
2006-07-04 8:20 ` Stephane Eranian
2006-07-04 9:05 Mikael Pettersson
2006-07-04 10:22 ` Andi Kleen
2006-07-04 9:20 Mikael Pettersson
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=1152001336.3109.10.camel@laptopd505.fenrus.org \
--to=arjan@infradead.org \
--cc=ak@suse.de \
--cc=eranian@hpl.hp.com \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®