[Perfapi-devel] profile programs every 10M instructions

lulu he loloseed at gmail.com
Sat Jul 10 01:37:42 EDT 2010


Hi Gary,

Thanks for your reply.

But I wanna collect statistics on CMPs ,
Is HPCToolkit suit to profile CMPs?
Or pfmon is better on CMPs?

Thanks.

2010/7/8  <Gary.Mohr at bull.com>:
> HI,
>
> The HPCToolkit package available from Rice University provides tools that
> already do the type
> of things described below.  You may want to take a look at it to see if it
> can provide what you are
> looking for.
>
> http://hpctoolkit.org/
>
> Gary
>
> perfapi-devel-bounces at eecs.utk.edu wrote on 07/08/2010 03:10:49 AM:
>
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>>
>> Hello,
>>
>>   I think that PAPI developers can help you more about this, because I
>> typically use it in the 1st person mode (i.e., I count my own
>> instructions, cycles, and so on).
>>
>>   To do what you propose that, I think you should explore code
>> interposition. Two ideas come to my mind now. First, if your 10M_profile
>> program could preload a shared library inside the benchmark process and
>> set up the overflow handler inside the library. To do that you should
>> read these references [1] and [2]. For [1] look for
>> constructor/destructor function attributes and check how your compiler
>> does that. On [2] there's more information about code interposition &
>> LD_PRELOAD.
>>   The second idea is that your 10M_profile uses a code interposition
>> library called DynInst[3] -- which in fact is a more evolutioned
>> solution that the previous one.
>>
>>   Those were my 2 euro cents :)
>>
>>   But as I stated before, maybe the PAPI team can help you a bit more
>> about this question.
>>
>> [1] http://linux.die.net/man/3/dlopen
>> [2] http://developers.sun.com/solaris/articles/lib_interposers.html
>> [3] http.//www.dyninst.org
>>
>> Regards.
>>
>> En/na lulu he ha escrit:
>> > Hi Harald Servat,
>> >
>> > thanks for your quick response.
>> >
>> > I am new to PAPI,
>> > must PAPI instrument source code to profile program?
>> > Can I write my tool, like 10M_profile, and profile program in the
>> > command line like this:
>> > [root at localhost]# ./10M_profile benchmark
>> >
>> > 2010/7/8 Harald Servat <harald.servat at bsc.es>:
>> >
>> > Hello,
>> >
>> >  do you need to profile exactly at 10M instructions? If not, you could
>> > consider using software sampling which is supported by PAPI. Although
>> > software sampling is not as accurate as hardware sampling, if you need
>> > to report performance data based on these 10Minstructions, you could
>> > extrapolate somehow by getting the current instructions (and the rest
> of
>> > performance metrics you're interested on) at each sample point.
>> >
>> >  See http://icl.cs.utk.edu/projects/papi/wiki/PAPI3:PAPI_overflow.3 for
>> > more information on sampling and software sampling using PAPI.
>> >
>> > Regards.
>> >
>> > En/na lulu he ha escrit:
>> >>>> Hi,
>> >>>>
>> >>>> I wanna profile program every 10M instructions.
>> >>>> But it seems that the hardware does not support instrction-
>> based profiling,
>> >>>> So, I have not found a solution yet.
>> >>>>
>> >>>> I have the following plan:
>> >>>> For Sequential program,
>> >>>> get profile data(i.e., cyclys, L2 cache misses, L2 cache accesses)
>> >>>> every 10M instructions.
>> >>>>
>> >>>> For Parallel program:
>> >>>> 1st : get profile data(ie, cyclys) every 10M instructions of each
> thread.
>> >>>> 2nd: get profile data every 10M instructions of total threads.
>> >>>>
>> >>>> Is this able to be done with existing profiling tools , API , or ABI
> ?
>> >>>> An easy solution with tools will be appreciated.
>> >>>>
>> >>>> Thanks.
>> >>>> _______________________________________________
>> >>>> Perfapi-devel mailing list
>> >>>> Perfapi-devel at eecs.utk.edu
>> >>>> http://lists.eecs.utk.edu/mailman/listinfo/perfapi-devel
>> >>
>>
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v2.0.9 (GNU/Linux)
>>
>> iEYEARECAAYFAkw1pCkACgkQwMPeuqUCg9y3WQCfQROOZFvJK9GIz7VxEU1v9Dji
>> LYEAnRjqiHKYGcj+82NbS05psTGBOded
>> =LIQC
>> -----END PGP SIGNATURE-----
>> _______________________________________________
>> Perfapi-devel mailing list
>> Perfapi-devel at eecs.utk.edu
>> http://lists.eecs.utk.edu/mailman/listinfo/perfapi-devel
>
>



-- 
LuLu He
Cluster and Grid Computing Lab (CGCL)
Services Computing Technology and System Lab (SCTS)
School of Computer Science and Technology (CS)
Huazhong University of Science and Technology (HUST)
Wuhan, 430074, China


More information about the Perfapi-devel mailing list