Ah, okay, it had occurred to me that might be the case, but I don't have root on that machine so I couldn't test it before asking on the list. Is there a way to uniquely measure a multithreaded application that doesn't require root? I tried just using something like task or task_smpl, but on a pthread application with two threads it only appears to monitor the main thread and not the worker child (based on a comparison of instruction count from task and from Pin).
-dan On Fri, Jul 15, 2011 at 5:03 PM, Vince Weaver <vweav...@eecs.utk.edu> wrote: > On Fri, 15 Jul 2011, Dan Upton wrote: > >> I'm trying to monitor some multithreaded applications and I just found >> the task_cpu example tool. I can't get it to attach to any program >> though, single or multithreaded, even something as simple as ls: >> >> $ ./task_cpu -- /bin/ls >> task_cpu: cannot attach event0 PERF_COUNT_HW_CPU_CYCLES: Permission denied >> >> However, task_smpl and task work fine. Is something special required >> to get task_cpu to work? > > For security reasons you need root permission to access the CPU-level > counters. This is because when you monitor CPU-wide you monitor *all* > processes on the CPU, including ones that don't belong to you. > > Vince > ------------------------------------------------------------------------------ AppSumo Presents a FREE Video for the SourceForge Community by Eric Ries, the creator of the Lean Startup Methodology on "Lean Startup Secrets Revealed." This video shows you how to validate your ideas, optimize your ideas and identify your business strategy. http://p.sf.net/sfu/appsumosfdev2dev _______________________________________________ perfmon2-devel mailing list perfmon2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perfmon2-devel