This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [PATCH v2 2.6.38-rc8-tip 6/20] 6: x86: analyze instruction and determine fixups.
- From: Srikar Dronamraju <srikar at linux dot vnet dot ibm dot com>
- To: Thomas Gleixner <tglx at linutronix dot de>
- Cc: Peter Zijlstra <peterz at infradead dot org>, Ingo Molnar <mingo at elte dot hu>, Steven Rostedt <rostedt at goodmis dot org>, Linux-mm <linux-mm at kvack dot org>, Arnaldo Carvalho de Melo <acme at infradead dot org>, Linus Torvalds <torvalds at linux-foundation dot org>, Andi Kleen <andi at firstfloor dot org>, Christoph Hellwig <hch at infradead dot org>, Masami Hiramatsu <masami dot hiramatsu dot pt at hitachi dot com>, Oleg Nesterov <oleg at redhat dot com>, Andrew Morton <akpm at linux-foundation dot org>, SystemTap <systemtap at sources dot redhat dot com>, Jim Keniston <jkenisto at linux dot vnet dot ibm dot com>, Roland McGrath <roland at hack dot frob dot com>, Ananth N Mavinakayanahalli <ananth at in dot ibm dot com>, LKML <linux-kernel at vger dot kernel dot org>, "Paul E. McKenney" <paulmck at linux dot vnet dot ibm dot com>
- Date: Fri, 18 Mar 2011 23:54:57 +0530
- Subject: Re: [PATCH v2 2.6.38-rc8-tip 6/20] 6: x86: analyze instruction and determine fixups.
- References: <20110314133403.27435.7901.sendpatchset@localhost6.localdomain6> <20110314133507.27435.71382.sendpatchset@localhost6.localdomain6> <alpine.LFD.2.00.1103151529130.2787@localhost6.localdomain6>
- Reply-to: Srikar Dronamraju <srikar at linux dot vnet dot ibm dot com>
>
> > + ret = handle_riprel_insn(uprobe, &insn);
> > + if (ret == -1)
> > + /* rip-relative; can't XOL */
> > + return 0;
>
> So we return -1 from handle_riprel_insn() and return success?
handle_riprel_insn() returns 0 if the instruction is not rip-relative
returns 1 if its rip-relative but can use XOL slots.
returns -1 if its rip-relative but cannot use XOL.
We dont see any instructions that are rip-relative and cannot use XOL.
so the check and return are redundant and I will remove that in the next
patch.
Btw how
> deals handle_riprel_insn() with 32bit user space ?
>
handle_riprel_insn() calls insn_rip_relative() which fails if
instruction isnot rip-relative and handle_riprel_insn returns
immediately.
The rest of your suggestions for this patch are taken.
> > +#endif
> > + prepare_fixups(uprobe, &insn);
> > + return 0;
>
--
Thanks and Regards
Srikar