One detail: As I've mentioned in other messages on the subject, you can set up a "system-wide" session using pfmon to count the NB events. This will continue to count even when the thread that started the session sleeps.
Drongowski, Paul wrote: > Hello Sergey -- > > Just to add a few comments to Stephane's. > > Northbridge resources are shared across all cores > in the "node" (the cores that are local to the > Northbridge and communicate directly with the NB). > Northbridge events measure memory controller events, > crossbar events, HyperTransport(tm) events and > L3 cache events. The events generally do not break > out by core, i.e., these X events belong to core 0, > these Y events belong to core 1, etc. They measure > events due to requests, etc. across all local cores. > > If all cores are measuring the same NB event, the > events will be counted multiple times -- not good. > So, perfmon2 follows the recommended practice, which is > to measure NB events on a single core > belonging to a given NB. > > There's one potential gotcha. The core measuring > the NB events cannot go into halt mode (idle) as the > clock for the performance counter logic may be stopped > and events are not counted. It may be necessary to > keep the core awake by running a low-priority > background task. > > More information concerning Northbridge events can be > found in Section 3.12 of the BIOS and Kernel Developer's > Guide (BKDG) for AMD Family 10h processors. > > -- pj > > > -----Original Message----- > From: stephane eranian [mailto:eran...@googlemail.com] > Sent: Friday, October 30, 2009 6:59 PM > To: Sergey Blagodurov > Cc: perfmon2-devel@lists.sourceforge.net > Subject: Re: [perfmon2] same counter values for several processes > onBarcelona > > Sergey, > > On Fri, Oct 30, 2009 at 11:23 PM, Sergey Blagodurov > <blagodu...@gmail.com> wrote: >> Hello, >> >> I have the following problem while trying to gather hardware counters >> on Barcelona: whenever I start several programs with the same counter >> profiling on AMD Barcelona, all of the program invocations except the >> first failing with conflicting monitoring session error. The problem >> can be revealed with smth like that: >> >> $ pfmon --events=MEMORY_CONTROLLER_REQUESTS:READ_REQUESTS sleep 20 & >> [1] >> $ pfmon --events=MEMORY_CONTROLLER_REQUESTS:READ_REQUESTS sleep 20 & >> error conflicting monitoring session exists >> > > This is due to a constraint on all Northbridge events. > The way the current perfmon code implements the restriction is to > limit the number of perfmon > sessions which have access to NB events to 1 per socket in system-wide > and 1 global in per-thread > mode. > > >> There is no such behaviour on Intel Xeon processors. I wonder what may >> cause this strange problem and are there any workarounds to it (i.e. >> is it still possible to gather same counter info for several >> programs/threads at the same time)? >> >> Thank you! >> >> -- >> Sincerely, >> >> Sergey Blagodurov >> > > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > perfmon2-devel mailing list > perfmon2-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/perfmon2-devel ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ perfmon2-devel mailing list perfmon2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perfmon2-devel