How to use ocelot for the GPU runtime performance monitor

93 views
Skip to first unread message

cheng luo

unread,
Nov 28, 2010, 5:51:54 AM11/28/10
to gpuocelot
Hi, I would like to monitor some performance character such as memory
access rate, utilization of GPU(how many MP are used or how many SP
are used.). Where should I insert my printf statement code in the
ocelot source code? Thank you.

Diamos, Gregory F

unread,
Nov 28, 2010, 3:23:24 PM11/28/10
to gpuo...@googlegroups.com
Ocelot includes multiple methods for running a CUDA program including a functional simulator and native GPU and CPU targets. The emulator has a trace generation interface ( http://code.google.com/p/gpuocelot/wiki/TraceGeneration ) that allows you to write a callback functor that can examine the state of the program and record metrics that are visible at the ISA level, but not the microarchitecture level. So you would be able to record the memory accesses that the program is making, but not the utiltization of the MPs. If you want to measure something at the microarchitecture level, you would want to either use an architecture simulator like MACSIM or GPGPU-SIM, or write a timing model for Ocelot. You could take a look at the cache simulator in Ocelot ( http://code.google.com/p/gpuocelot/source/browse/trunk/trace-generators/traces/implementation/CacheSimulator.cpp ) for an example of an existing timing model.

Regards,

Greg

--
You received this message because you are subscribed to the Google Groups "gpuocelot" group.
To post to this group, send email to gpuo...@googlegroups.com.
To unsubscribe from this group, send email to gpuocelot+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/gpuocelot?hl=en.

cheng luo

unread,
Dec 5, 2010, 6:43:59 AM12/5/10
to gpuo...@googlegroups.com
Thanks, Now, I install ocelot and face a lot of problems.
Before install ocelot I need to install hydranize. 
And I use svn checkout http://hydrazine.googlecode.com/svn/trunk/ hydrazine-read-only
to download it.
I sereach with google find the following installment command:
cd hydrazine; libtoolize; aclocal; autoconf; automake; ./configure; sudo make install 
So I cd into the /hydrazine-read-only/hydrazine
and run the command sudo libtoolize and it work
and I run sudo aclocal it says :
aclocal: `configure.ac' or `configure.in' is required
 
Where is the configure? How can I install this correctly.
Thank you very much.

2010/11/29 Diamos, Gregory F <Gregory...@gatech.edu>

Gregory Diamos

unread,
Dec 5, 2010, 10:46:08 AM12/5/10
to gpuo...@googlegroups.com
Hi Cheng,

Current versions of Ocelot (from svn and the most recent download)
include hydrazine automatically. You should just be able to run the
configure script and makefiles in the main Ocelot directory.

Regards,

Greg

On 12/05/2010 03:43 AM, cheng luo wrote:
> Thanks, Now, I install ocelot and face a lot of problems.
> Before install ocelot I need to install hydranize.

> And I use svn checkout */http/*://hydrazine.googlecode.com/svn/trunk/


> <http://hydrazine.googlecode.com/svn/trunk/> hydrazine-read-only
> to download it.
> I sereach with google find the following installment command:
> cd hydrazine; libtoolize; aclocal; autoconf; automake; ./configure; sudo
> make install
> So I cd into the /hydrazine-read-only/hydrazine
> and run the command sudo libtoolize and it work
> and I run sudo aclocal it says :

> aclocal: `configure.ac <http://configure.ac>' or `configure.in
> <http://configure.in>' is required


> Where is the configure? How can I install this correctly.
> Thank you very much.
>
> 2010/11/29 Diamos, Gregory F <Gregory...@gatech.edu

> <mailto:Gregory...@gatech.edu>>

> <mailto:gpuo...@googlegroups.com>.


> To unsubscribe from this group, send email to
> gpuocelot+...@googlegroups.com

> <mailto:gpuocelot%2Bunsu...@googlegroups.com>.


> For more options, visit this group at
> http://groups.google.com/group/gpuocelot?hl=en.
>
> --
> You received this message because you are subscribed to the Google
> Groups "gpuocelot" group.
> To post to this group, send email to gpuo...@googlegroups.com

> <mailto:gpuo...@googlegroups.com>.


> To unsubscribe from this group, send email to
> gpuocelot+...@googlegroups.com

> <mailto:gpuocelot%2Bunsu...@googlegroups.com>.

cheng luo

unread,
Dec 5, 2010, 9:29:58 PM12/5/10
to gpuo...@googlegroups.com
Hi Greg,
Thank you for your answer. I have finished the installment and I take an example of the tracegenerater.
I run the tracegeneration example code published on the website. And I have the following
error:
-----------------------------------------------------------------------
sudaken11:~/Desktop/ocelot-1.1.560> ./tracegen
terminate called after throwing an instance of 'hydrazine::Exception'
  what():  invalid value
Abort
-----------------------------------------------------------------------
what dose this error mean?
How can I handle this error?

2010/12/6 Gregory Diamos <Gregory...@gatech.edu>

Gregory Diamos

unread,
Dec 6, 2010, 12:09:19 PM12/6/10
to gpuo...@googlegroups.com
Hi Cheng,

This error is reported directly from the CUDA driver, meaning that an
NVIDIA GPU device is selected. The error is more verbose in more recent
versions, but you can only run trace generators on the Emulator device.
You need to edit your configure.ocelot file to select the 'emulated'
device only.

Regards,

Greg

On 12/05/2010 06:29 PM, cheng luo wrote:
> Hi Greg,
> Thank you for your answer. I have finished the installment and I take an
> example of the tracegenerater.
> I run the tracegeneration example code published on the
> website. And I have the following
> error:
> -----------------------------------------------------------------------
> sudaken11:~/Desktop/ocelot-1.1.560> ./tracegen
> terminate called after throwing an instance of 'hydrazine::Exception'
> what(): invalid value
> Abort
> -----------------------------------------------------------------------
> what dose this error mean?
> How can I handle this error?
>
> 2010/12/6 Gregory Diamos <Gregory...@gatech.edu

> <mailto:Gregory...@gatech.edu>>

> <mailto:Gregory...@gatech.edu

> <mailto:gpuo...@googlegroups.com


> <mailto:gpuo...@googlegroups.com>>.
>
> To unsubscribe from this group, send email to
> gpuocelot+...@googlegroups.com
> <mailto:gpuocelot%2Bunsu...@googlegroups.com>

> <mailto:gpuocelot%2Bunsu...@googlegroups.com
> <mailto:gpuocelot%252Buns...@googlegroups.com>>.


>
> For more options, visit this group at
> http://groups.google.com/group/gpuocelot?hl=en.
>
> --
> You received this message because you are subscribed to the
> Google
> Groups "gpuocelot" group.
> To post to this group, send email to
> gpuo...@googlegroups.com <mailto:gpuo...@googlegroups.com>

> <mailto:gpuo...@googlegroups.com


> <mailto:gpuo...@googlegroups.com>>.
>
> To unsubscribe from this group, send email to
> gpuocelot+...@googlegroups.com
> <mailto:gpuocelot%2Bunsu...@googlegroups.com>

> <mailto:gpuocelot%2Bunsu...@googlegroups.com
> <mailto:gpuocelot%252Buns...@googlegroups.com>>.

cheng luo

unread,
Dec 8, 2010, 1:59:22 AM12/8/10
to gpuo...@googlegroups.com
Hi Greg,
It seems there are some different between the ocelot-1.1.560.tar.bz2   from the websize directly and the ocelot download by SVN.
I reinstall with the the SVN version, and at the finial step "make" I have the following error:
========================================
hydrazine/implementation/ArgumentParser.cpp: In member function ‘void hydrazine::ArgumentParser::parse()’:
hydrazine/implementation/ArgumentParser.cpp:157: error: ‘exit’ was not declared in this scope
make[1]: *** [libocelot_la-ArgumentParser.lo] Error 1
make[1]: Leaving directory `/home/skkk/Desktop/gpuocelot/ocelot'
make: *** [all] Error 2
==========================================
Something wrong with the hydrazine, but the hydrazine should be automatinclly installed by ocelot.
How can I solve this error?
Thank you very much.

2010/12/7 Gregory Diamos <Gregory...@gatech.edu>

Gregory Diamos

unread,
Dec 8, 2010, 2:12:02 AM12/8/10
to gpuo...@googlegroups.com
Try checking it out again.� exit is included in cstdlib, which was not explicitly included in ArgumentParser.� This builds successfully on every machine that I have tried without including it, but I added it anyways.� Hopefully this will fix your issue.

Regards,

Greg


On 12/07/2010 10:59 PM, cheng luo wrote:
Hi Greg,
It seems there are some different between the�ocelot-1.1.560.tar.bz2 ��from the websize directly and the ocelot download by SVN.
I reinstall with the the SVN version, and at the finial step "make" I have the following error:
========================================
hydrazine/implementation/ArgumentParser.cpp: In member function �void hydrazine::ArgumentParser::parse()�:
hydrazine/implementation/ArgumentParser.cpp:157: error: �exit� was not declared in this scope
make[1]: *** [libocelot_la-ArgumentParser.lo] Error 1
make[1]: Leaving directory `/home/skkk/Desktop/gpuocelot/ocelot'
make: *** [all] Error 2
==========================================
Something wrong with the hydrazine, but the hydrazine should be automatinclly installed by ocelot.
How can I solve this error?
Thank you very much.

2010/12/7 Gregory Diamos <Gregory...@gatech.edu>
Hi Cheng,

This error is reported directly from the CUDA driver, meaning that an NVIDIA GPU device is selected. The error is more verbose in more recent versions, but you can only run trace generators on the Emulator device. �You need to edit your configure.ocelot file to select the 'emulated' device only.


Regards,

Greg


On 12/05/2010 06:29 PM, cheng luo wrote:
Hi Greg,
Thank you for your answer. I have finished the installment and I take an
example of the tracegenerater.
I run the tracegeneration example code published on the
website. And I have the following
error:
-----------------------------------------------------------------------
sudaken11:~/Desktop/ocelot-1.1.560> ./tracegen
terminate called after throwing an instance of 'hydrazine::Exception'
� what(): �invalid value

Abort
-----------------------------------------------------------------------
what dose this error mean?
How can I handle this error?

2010/12/6 Gregory Diamos <Gregory...@gatech.edu
� �Hi Cheng,

� �Current versions of Ocelot (from svn and the most recent download)
� �include hydrazine automatically. �You should just be able to run the
� �configure script and makefiles in the main Ocelot directory.

� �Regards,

� �Greg


� �On 12/05/2010 03:43 AM, cheng luo wrote:

� � � �Thanks, Now, I install ocelot and face a lot of problems.
� � � �Before install ocelot I need to install hydranize.
� � � �And I use svn checkout
� � � �*/http/*://hydrazine.googlecode.com/svn/trunk/
� � � �<http://hydrazine.googlecode.com/svn/trunk/>
� � � �<http://hydrazine.googlecode.com/svn/trunk/> hydrazine-read-only
� � � �to download it.
� � � �I sereach with google find the following installment command:
� � � �cd hydrazine; libtoolize; aclocal; autoconf; automake;
� � � �./configure; sudo
� � � �make install
� � � �So I cd into the /hydrazine-read-only/hydrazine
� � � �and run the command sudo libtoolize and it work
� � � �and I run sudo aclocal it says :
� � � �aclocal: `configure.ac <http://configure.ac>
� � � �<http://configure.ac>' or `configure.in <http://configure.in>
� � � �<http://configure.in>' is required

� � � �Where is the configure? How can I install this correctly.
� � � �Thank you very much.

� � � �2010/11/29 Diamos, Gregory F <Gregory...@gatech.edu
� � � �<mailto:Gregory...@gatech.edu>
� � � �<mailto:Gregory...@gatech.edu
� � � �<mailto:Gregory...@gatech.edu>>>


� � � � � �Ocelot includes multiple methods for running a CUDA program
� � � � � �including a functional simulator and native GPU and CPU targets.
� � � � � � �The emulator has a trace generation interface (
� � � �http://code.google.com/p/gpuocelot/wiki/TraceGeneration ) that
� � � � � �allows you to write a callback functor that can examine the
� � � �state of
� � � � � �the program and record metrics that are visible at the ISA
� � � �level,
� � � � � �but not the microarchitecture level. �So you would be able
� � � �to record
� � � � � �the memory accesses that the program is making, but not the
� � � � � �utiltization of the MPs. �If you want to measure something
� � � �at the
� � � � � �microarchitecture level, you would want to either use an
� � � � � �architecture simulator like MACSIM or GPGPU-SIM, or write a
� � � �timing
� � � � � �model for Ocelot. �You could take a look at the cache
� � � �simulator in
� � � � � �Ocelot (
� � � �http://code.google.com/p/gpuocelot/source/browse/trunk/trace-generators/traces/implementation/CacheSimulator.cpp
� � � � � �) for an example of an existing timing model.

� � � � � �Regards,

� � � � � �Greg

� � � � � �----- Original Message -----
� � � � � �From: "cheng luo" <cheng...@gmail.com
� � � �<mailto:cheng...@gmail.com> <mailto:cheng...@gmail.com
� � � �<mailto:cheng...@gmail.com>>>
� � � � � �To: "gpuocelot" <gpuo...@googlegroups.com
� � � �<mailto:gpuo...@googlegroups.com>
� � � �<mailto:gpuo...@googlegroups.com
� � � �<mailto:gpuo...@googlegroups.com>>>
� � � � � �Sent: Sunday, November 28, 2010 2:51:54 AM
� � � � � �Subject: [gpuocelot] How to use ocelot for the GPU runtime
� � � � � �performance monitor

� � � � � �Hi, I would like to monitor some performance character such
� � � �as memory
� � � � � �access rate, utilization of GPU(how many MP are used or how
� � � �many SP
� � � � � �are used.). Where should I insert my printf statement code
� � � �in the
� � � � � �ocelot source code? Thank you.

� � � � � �--
� � � � � �You received this message because you are subscribed to the
� � � �Google
� � � � � �Groups "gpuocelot" group.
� � � � � �To post to this group, send email to
� � � �gpuo...@googlegroups.com <mailto:gpuo...@googlegroups.com>
� � � �<mailto:gpuo...@googlegroups.com

� � � �<mailto:gpuo...@googlegroups.com>>.

� � � � � �To unsubscribe from this group, send email to
� � � �gpuocelot+...@googlegroups.com
� � � �<mailto:gpuocelot%2Bunsu...@googlegroups.com>
� � � �<mailto:gpuocelot%2Bunsu...@googlegroups.com
� � � �<mailto:gpuocelot%252Buns...@googlegroups.com>>.


� � � � � �For more options, visit this group at
� � � �http://groups.google.com/group/gpuocelot?hl=en.

� � � � � �--
� � � � � �You received this message because you are subscribed to the
� � � �Google
� � � � � �Groups "gpuocelot" group.
� � � � � �To post to this group, send email to
� � � �gpuo...@googlegroups.com <mailto:gpuo...@googlegroups.com>
� � � �<mailto:gpuo...@googlegroups.com

� � � �<mailto:gpuo...@googlegroups.com>>.

� � � � � �To unsubscribe from this group, send email to
� � � �gpuocelot+...@googlegroups.com
� � � �<mailto:gpuocelot%2Bunsu...@googlegroups.com>
� � � �<mailto:gpuocelot%2Bunsu...@googlegroups.com
� � � �<mailto:gpuocelot%252Buns...@googlegroups.com>>.


� � � � � �For more options, visit this group at
� � � �http://groups.google.com/group/gpuocelot?hl=en.


� � � �--
� � � �You received this message because you are subscribed to the Google
� � � �Groups "gpuocelot" group.
� � � �To post to this group, send email to gpuo...@googlegroups.com
� � � �<mailto:gpuo...@googlegroups.com>.
� � � �To unsubscribe from this group, send email to
� � � �gpuocelot+...@googlegroups.com
� � � �<mailto:gpuocelot%2Bunsu...@googlegroups.com>.
� � � �For more options, visit this group at
� � � �http://groups.google.com/group/gpuocelot?hl=en.


� �--
� �You received this message because you are subscribed to the Google
� �Groups "gpuocelot" group.
� �To post to this group, send email to gpuo...@googlegroups.com
� �<mailto:gpuo...@googlegroups.com>.
� �To unsubscribe from this group, send email to
� �gpuocelot+...@googlegroups.com
� �<mailto:gpuocelot%2Bunsu...@googlegroups.com>.
� �For more options, visit this group at
� �http://groups.google.com/group/gpuocelot?hl=en.



--
You received this message because you are subscribed to the Google
Groups "gpuocelot" group.
To post to this group, send email to gpuo...@googlegroups.com.
To unsubscribe from this group, send email to
gpuocelot+...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/gpuocelot?hl=en.

--
You received this message because you are subscribed to the Google Groups "gpuocelot" group.
To post to this group, send email to gpuo...@googlegroups.com.
To unsubscribe from this group, send email to gpuocelot+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/gpuocelot?hl=en.

Reply all
Reply to author
Forward
0 new messages