|
From: Milind <km...@gm...> - 2010-01-12 14:37:46
|
Hi Josef, On Tue, Jan 12, 2010 at 7:47 PM, Josef Weidendorfer < Jos...@gm...> wrote: > Hi Milind, > > On Tuesday 12 January 2010, Milind wrote: > > Thanks Josef for the reply. I am referring to CPU clock ticks and not the > > wall clock. > > with "wall clock", I actually meant any time source derived from real time > (including CPU clock ticks of the Valgrind process). > > > Couple of responses that I received also indicate that there is > > no real CPU clock tick simulation. > > How could there be? Valgrind does not enforce any performance model with > given time characteristics on you, and such a thing is not needed by > any Valgrind tool. So, how should it be able to provide you with a > clock tick simulation? > [milind] Ok. Got this now. > > > Let me see if I can cover my requirement > > with the cachegrind output. > > By multiplying the event counts from cachegrind output with penalties for > the > different event types, you can come up with clock tick estimations, yes. > [milind] can you elaborate little more ? :) Thanks, - Milind > > Josef > > > I am sure I wont need full-system simulators > > yet. > > > > Thanks, > > - Milind > > > > On Tue, Jan 12, 2010 at 6:45 PM, Josef Weidendorfer < > > Jos...@gm...> wrote: > > > > > Hi, > > > > > > On Tuesday 12 January 2010, Milind wrote: > > > > I have started exploring valgrind recently. I wanted to know if > valgrind > > > > core keeps track of the CPU clock ticks. > > > > > > Which ticks do you mean? Wall clock time makes not much sense, as this > > > would > > > include all housekeeping tasks Valgrind is doing, such as > instrumentation > > > of > > > client code. So, there really is no "CPU clock tick" to keep track of. > > > You have to maintain your own tick counter if you want something like > this. > > > > > > And how you want this counter to advance is totally up to you and > depends > > > on > > > the type of processor model you envision. E.g. you could include a > cache > > > model, > > > a branch predictor, latency/troughput parameters for different > instruction > > > types and so on, and advance the clock tick counter accordingly. > > > Just a note: it probably gets arbitrarily complex to approximate the > tick > > > counter > > > of a real processor; and this only will work for the user-level side > with > > > one > > > process. > > > > > > Perhaps it is better for you to look at cycle-accurate full-system > > > simulators? > > > > > > Josef > > > > > > > I want to record memory access > > > > pattern of my program. In that context, I wanted to record the CPU > clock > > > > tick value at the time of memory access. I want to feed output of > > > valgrind > > > > to DRAMsim which needs memory addr that is being accessed, access > type > > > > (read, write, etc) and the cpu clock time value when the access is > being > > > > done. Any pointers/links will help. > > > > > > > > Thanks, > > > > - Milind > > > > > > > > > > > > > > > > > > |