From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934121AbcFIGJc (ORCPT ); Thu, 9 Jun 2016 02:09:32 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:40902 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932424AbcFIGJa (ORCPT ); Thu, 9 Jun 2016 02:09:30 -0400 X-IBM-Helo: d23dlp02.au.ibm.com X-IBM-MailFrom: naveen.n.rao@linux.vnet.ibm.com X-IBM-RcptTo: linux-kernel@vger.kernel.org;netdev@vger.kernel.org Date: Thu, 9 Jun 2016 11:37:52 +0530 From: "Naveen N. Rao" To: Nilay Vaish Cc: Daniel Borkmann , Matt Evans , Alexei Starovoitov , netdev@vger.kernel.org, Denis Kirjanov , Linux Kernel list , Paul Mackerras , linuxppc-dev@lists.ozlabs.org, "David S. Miller" , Ananth N Mavinakayanahalli Subject: Re: [PATCH 6/6] ppc: ebpf/jit: Implement JIT compiler for extended BPF References: <908d3552b5eb240b28f70aee7c4c86e2b600aa02.1465304785.git.naveen.n.rao@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.0 (2016-04-01) X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16060906-0044-0000-0000-000001B268F5 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 16060906-0045-0000-0000-000004E5732D Message-Id: <20160609060752.GQ18654@naverao1-tp.localdomain> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-06-08_11:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=2 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1604210000 definitions=main-1606090062 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2016/06/08 10:19PM, Nilay Vaish wrote: > Naveen, can you point out where in the patch you update the variable: > idx, a member of codegen_contex structure? Somehow I am unable to > figure it out. I can only see that we set it to 0 in the > bpf_int_jit_compile function. Since all your test cases pass, I am > clearly overlooking something. Yes, that's being done in bpf_jit.h (see the earlier patches in the series). All the PPC_*() instruction macros are defined to EMIT() the respective powerpc instruction encoding. EMIT() translates to PLANT_INSTR(), which actually increments idx. - Naveen