From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37300) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZhihK-0002Na-SH for qemu-devel@nongnu.org; Thu, 01 Oct 2015 14:35:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZhihF-0000B8-43 for qemu-devel@nongnu.org; Thu, 01 Oct 2015 14:35:18 -0400 Received: from mail-bn1bon0069.outbound.protection.outlook.com ([157.56.111.69]:37916 helo=na01-bn1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZhihE-0000Au-WB for qemu-devel@nongnu.org; Thu, 01 Oct 2015 14:35:13 -0400 Date: Thu, 1 Oct 2015 11:35:09 -0700 From: "Edgar E. Iglesias" Message-ID: <20151001183509.GA29416@toto> References: <1442672127-26223-1-git-send-email-edgar.iglesias@gmail.com> <1442672127-26223-5-git-send-email-edgar.iglesias@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH RFC 4/8] target-arm: Avoid inline for get_phys_addr List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: "Edgar E. Iglesias" , Sergey Fedorov , Alex =?iso-8859-1?Q?Benn=E9e?= , QEMU Developers , Alexander Graf On Wed, Sep 23, 2015 at 09:58:10AM -0700, Peter Maydell wrote: > On 19 September 2015 at 07:15, Edgar E. Iglesias > wrote: > > From: "Edgar E. Iglesias" > > > > Avoid inline for get_phys_addr() to prepare for future recursive use. > > Does the compiler actually complain? Sorry for the late replies Peter... Yes the compiler complains if we keep the inline. I'll fix the indentation. Thanks, Edgar > > In any case this function is a lot more complex than it used to be so > we might as well just rely on the compiler's discretion about whether > to bother inlining it or not. > > > Signed-off-by: Edgar E. Iglesias > > --- > > target-arm/helper.c | 10 +++++----- > > 1 file changed, 5 insertions(+), 5 deletions(-) > > > > diff --git a/target-arm/helper.c b/target-arm/helper.c > > index 6f0ed51..7e7f29d 100644 > > --- a/target-arm/helper.c > > +++ b/target-arm/helper.c > > @@ -13,7 +13,7 @@ > > #include "exec/semihost.h" > > > > #ifndef CONFIG_USER_ONLY > > -static inline bool get_phys_addr(CPUARMState *env, target_ulong address, > > +static bool get_phys_addr(CPUARMState *env, target_ulong address, > > int access_type, ARMMMUIdx mmu_idx, > > hwaddr *phys_ptr, MemTxAttrs *attrs, int *prot, > > target_ulong *page_size, uint32_t *fsr); > > Might as well reindent these lines. > > > @@ -6967,10 +6967,10 @@ static bool get_phys_addr_pmsav5(CPUARMState *env, uint32_t address, > > * @page_size: set to the size of the page containing phys_ptr > > * @fsr: set to the DFSR/IFSR value on failure > > */ > > -static inline bool get_phys_addr(CPUARMState *env, target_ulong address, > > - int access_type, ARMMMUIdx mmu_idx, > > - hwaddr *phys_ptr, MemTxAttrs *attrs, int *prot, > > - target_ulong *page_size, uint32_t *fsr) > > +static bool get_phys_addr(CPUARMState *env, target_ulong address, > > + int access_type, ARMMMUIdx mmu_idx, > > + hwaddr *phys_ptr, MemTxAttrs *attrs, int *prot, > > + target_ulong *page_size, uint32_t *fsr) > > { > > if (mmu_idx == ARMMMUIdx_S12NSE0 || mmu_idx == ARMMMUIdx_S12NSE1) { > > /* TODO: when we support EL2 we should here call ourselves recursively > > -- > > 1.9.1 > > > > Otherwise: > Reviewed-by: Peter Maydell > > thanks > -- PMM