From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753017AbcFFRFC (ORCPT ); Mon, 6 Jun 2016 13:05:02 -0400 Received: from foss.arm.com ([217.140.101.70]:38036 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751217AbcFFRE7 (ORCPT ); Mon, 6 Jun 2016 13:04:59 -0400 Date: Mon, 6 Jun 2016 18:05:15 +0100 From: Will Deacon To: Zi Shen Lim Cc: "David S. Miller" , Catalin Marinas , Yang Shi , Alexei Starovoitov , Daniel Borkmann , netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next 2/3] arm64: bpf: optimize JMP_CALL Message-ID: <20160606170515.GK669@arm.com> References: <1465077630-633-1-git-send-email-zlim.lnx@gmail.com> <1465077630-633-2-git-send-email-zlim.lnx@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1465077630-633-2-git-send-email-zlim.lnx@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jun 04, 2016 at 03:00:29PM -0700, Zi Shen Lim wrote: > Remove superfluous stack frame, saving us 3 instructions for > every JMP_CALL. > > Signed-off-by: Zi Shen Lim > --- > arch/arm64/net/bpf_jit_comp.c | 3 --- > 1 file changed, 3 deletions(-) > > diff --git a/arch/arm64/net/bpf_jit_comp.c b/arch/arm64/net/bpf_jit_comp.c > index 51abc97..7ae304e 100644 > --- a/arch/arm64/net/bpf_jit_comp.c > +++ b/arch/arm64/net/bpf_jit_comp.c > @@ -578,11 +578,8 @@ emit_cond_jmp: > const u64 func = (u64)__bpf_call_base + imm; > > emit_a64_mov_i64(tmp, func, ctx); > - emit(A64_PUSH(A64_FP, A64_LR, A64_SP), ctx); > - emit(A64_MOV(1, A64_FP, A64_SP), ctx); > emit(A64_BLR(tmp), ctx); > emit(A64_MOV(1, r0, A64_R(0)), ctx); > - emit(A64_POP(A64_FP, A64_LR, A64_SP), ctx); > break; > } Is the jitted code intended to be unwindable by standard tools? Will