From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:34532) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uaopw-0000WF-L6 for qemu-devel@nongnu.org; Fri, 10 May 2013 11:02:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uaopv-0008CJ-Dw for qemu-devel@nongnu.org; Fri, 10 May 2013 11:02:20 -0400 Received: from e23smtp06.au.ibm.com ([202.81.31.148]:50118) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uaopu-0008C1-S4 for qemu-devel@nongnu.org; Fri, 10 May 2013 11:02:19 -0400 Received: from /spool/local by e23smtp06.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Sat, 11 May 2013 00:56:01 +1000 From: Anthony Liguori In-Reply-To: References: <1368196799-19982-1-git-send-email-afaerber@suse.de> Date: Fri, 10 May 2013 10:02:02 -0500 Message-ID: <87sj1uzxn9.fsf@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH for-1.5?] target-ppc: Drop unnecessary dynamic cast in ppc_env_get_cpu() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell , Andreas =?utf-8?Q?F=C3=A4rbe?= =?utf-8?Q?r?= Cc: pbonzini@redhat.com, "open list:PowerPC" , qemu-devel@nongnu.org, aurelien@aurel32.net, Alexander Graf Peter Maydell writes: > On 10 May 2013 15:39, Andreas F=C3=A4rber wrote: >> A transition from CPUPPCState to PowerPCCPU can be considered safe, >> just like PowerPCCPU::env access in the opposite direction. >> >> This should slightly improve interrupt performance. > >> static inline PowerPCCPU *ppc_env_get_cpu(CPUPPCState *env) >> { >> - return POWERPC_CPU(container_of(env, PowerPCCPU, env)); >> + return container_of(env, PowerPCCPU, env); >> } > > So if this is worthwhile shouldn't we be doing it for > all our CPUs? Ack. Regards, Anthony Liguori > > thanks > -- PMM