From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22609 invoked by alias); 27 Jul 2005 21:05:04 -0000 Mailing-List: contact systemtap-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sources.redhat.com Received: (qmail 22592 invoked by uid 22791); 27 Jul 2005 21:04:59 -0000 X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: Hitachi djprobe mechanism Date: Wed, 27 Jul 2005 21:05:00 -0000 Message-ID: <44BDAFB888F59F408FAE3CC35AB4704101E506F6@orsmsx409> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Hitachi djprobe mechanism Thread-Index: AcWSq2SM2/Bdzr3YQzuRQv/yt0eXDgAQtmeQ From: "Keshavamurthy, Anil S" To: "Masami Hiramatsu" , "Roland McGrath" Cc: "Richard J Moore" , "SystemTAP" , , "Satoshi Oshima" X-OriginalArrivalTime: 27 Jul 2005 21:04:40.0191 (UTC) FILETIME=[CDC308F0:01C592EE] X-Scanned-By: MIMEDefang 2.44 X-SW-Source: 2005-q3/txt/msg00133.txt.bz2 Hi Masami, The same paper you have mentioned below talks=20 about overwriting a single instruction at the instrumentation point as opposed to what djprobe is doing which is replacing multiple instruction( in order to overwrite 5 byte jmp instruction). Having to replace multiple instructions in order to insert a long jump instruction is a very dangerous thing as some processes on some cpu might have been preempted out in the middle of those instructions and are expected to continue from the middle of that instruction which is now a data for overwritten jump instruction. I think that overwriting just a single-instruction is always hazard-free and should be followed in djprobe.=20 The paper clearly explains how to achieve this using what is known as springboard technique. Please let me know your thoughts on this. -thanks, Anil =20 >-----Original Message----- >From: systemtap-owner@sources.redhat.com=20 >[mailto:systemtap-owner@sources.redhat.com] On Behalf Of=20 >Masami Hiramatsu >Sent: Wednesday, July 27, 2005 6:02 AM >To: Roland McGrath >Cc: Richard J Moore; SystemTAP; sugita@sdl.hitachi.co.jp;=20 >Satoshi Oshima >Subject: Re: Hitachi djprobe mechanism > >Hi, Roland > >Roland McGrath wrote: >>> I think Kerninst is similar in effect to djprobe. both of them copy >>>original code to a buffer and jump to the buffer. >>> However I think that the most unique feature of djprobe is use of >>>"bypass" route to safely insert code on SMP. >>> I cannot find SMP safety mechanism like "bypass" in kerninst papers >>>yet. >>=20 >>=20 >> If by this you mean inserting an int3 while writing the rest=20 >of the jmp >> instruction and then overwriting the first byte when the=20 >rest is in place, >> I recall reading about that in some kerninst paper to be sure. > >Thanks a lot. >Finally, I found it in page.9 of the OSDI paper: >"Fine-Grained Dynamic Instrumentation of Commodity Operating=20 >System Kernels", >Ariel Tamches and Barton P. Miller, OSDI, Feb 1999. > >Actually, it seems to describe a similar thing. > >--=20 >Masami HIRAMATSU >2nd Research Dept. >Hitachi, Ltd., Systems Development Laboratory >E-mail: hiramatu@sdl.hitachi.co.jp > > > >