From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andi Kleen Subject: Re: [PATCH] KVM: Move KVM context switch into own function Date: Wed, 20 Oct 2010 18:20:41 +0200 Message-ID: <20101020162041.GF20124@basil.fritz.box> References: <1287590177-25094-1-git-send-email-andi@firstfloor.org> <4CBF14DB.5020109@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Andi Kleen , mtosatti@redhat.com, kvm@vger.kernel.org, Andi Kleen To: Avi Kivity Return-path: Received: from one.firstfloor.org ([213.235.205.2]:49775 "EHLO one.firstfloor.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752844Ab0JTQUn (ORCPT ); Wed, 20 Oct 2010 12:20:43 -0400 Content-Disposition: inline In-Reply-To: <4CBF14DB.5020109@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Wed, Oct 20, 2010 at 06:12:11PM +0200, Avi Kivity wrote: > On 10/20/2010 05:56 PM, Andi Kleen wrote: > >From: Andi Kleen > > > >gcc 4.5 with some special options is able to duplicate the VMX > >context switch asm in vmx_vcpu_run(). This results in a compile error > >because the inline asm sequence uses an on local label. The non local > >label is needed because other code wants to set up the return address. > > > > Curious, any idea why gcc does that? I guess it's the unlikely() > near the top. Don't know why, i wasn't motivated to go through its debugging dumps for this. But strictly the problem could always happen, not even a "volatile" stops that. -Andi