Mailing List
Home
Forum Home
Softimage
Carrara
trueSpace
Dir3d-l
Maya - a powerful 3D animation and visual effects software
Macromedia Flash Development
Subjects
Cameras
scaleDown command
black out solved
Aircraft Tutorial
Mathematical XYZ ?
Its done This vs That
Its done first week
recommendations for screen video captures?
3DExplorer "Oddity "
New Director
ProTeam renewals
Fuel 's new websites (X post)
Blue peter create a make toy
targeting groups question
XPost: Shockwave 3D game ( sort of )
RES: RES: RES: Fish Modeling
Emitting particles from object intersection
Fuel 's new websites (X post)
Texturing
Big Break Contest Videos
New Plugins
Models and Texture on my updated site
Error Installing Patch tS6 6
Plasma?
Looking for Inspiration
Weird EMail Q
It 's done first week ?
Cherry not cranberry
New game
Camera Animation Problem
Particle plugins?
 
Benchmarking C++ operators

Benchmarking C++ operators

2004-06-01       - By Helge Mathee

 Back
Reply:     1     2     3     4     5     6     7     8  

really?

thanks for sharing.....

good one.
 -- -- Original Message -- --
 From: Guy Rabiller
 To: XSI@(protected)
 Sent: Tuesday, June 01, 2004 5:12 PM
 Subject: Re: Benchmarking C++ operators


 On factor to enhance the speed of any operator, is to not query the ports and
parameters with string names.
 Rather use indexes with GetPortAt and GetParameters.
 You might get considerable speed enhancement.

--
guy rabiller | 3d technical director @ LaMaison


 Felix Gebhardt wrote:

Luc-Eric Rousseau wrote:
 
right, QueryPerformanceCounter is what we
use for mesuring an operator's performance.
   

Now I only need to actually HAVE your operator's performance. But hey, at
least we use the same timer ;)

Thanks for telling,
Felix



 
-- --Original Message-- --
From: owner-xsi@(protected) [mailto:owner-xsi@(protected)]On Behalf
Of Felix Gebhardt
Posted At: Tuesday, June 01, 2004 10:08 AM
Posted To: xsi
Conversation: Benchmarking C++ operators
Subject: Re: Benchmarking C++ operators


Hi Daniel, thanks for helping out,

I already had a look at VTune. Like you said. It's way overdosed for my
purpose and too expensive to setup. I will have a look at the MSVC option
but I also found something interesting on codeproject.
http://www.codeproject.com/cpp/precisetimer.asp


If there is anything else, keep em coming,
Felix




Daniel Bachler wrote:
   
Well there is Intels Vtune, but it's quite expensive (although I think
that there is a trial version available) and it can be a bit tough to set
up so that it returns some usefull information. MSVC has some kind of
profiler of its own IIRC, but without any graphical representation or
anything fancy. And, last but not least, you can of course take
timestamps yourself everytime you operator gets called and everytime it
returns and measuring that time. If it's something simple I would first
try the last trick, it's quite fast to setup and very precise, as the
time you loose on profiling is really negligible. If you want to take it
a step further you can store an array of simple structures containing
last starttime and amount of time in that block, then write two small
function, like this: (C++ style pseudocode)

Void StartBlock(int blockIndex)
{
m_ProfilerStructures[blockIndex].m_Starttime = gettime();
}

Void EndBlock(int blockIndex)
{
m_ProfilerStructures[blockIndex].m_ElapsedTime += gettime() -
m_ProfilerStructures[blockIndex].m_Startime();
}

You can then use it like this:

StartBlock(INIT);
Initialize();
EndBlock(INIT);
StartBlock(MAIN);
DoStruff();
EndBlock(MAIN);

Daniel

     
-- --Original Message-- --
From: owner-xsi@(protected)
[mailto:owner-xsi@(protected)] On Behalf Of Felix Gebhardt
Sent: Tuesday, June 01, 2004 2:22 PM
To: XSI@(protected)
Subject: Benchmarking C++ operators

Hi all,

does anyone happen to have an advise on what's the best way
to benchmark
compiled operators? In VBS I just would take a time snapshot
but it's not
too precise. How to nail it down better in C++? Any simple
but precise way
or free and easy to use analyzer/profiler?

Suggestions greatly appreciated,
Felix
       
---
Unsubscribe? Mail Majordomo@(protected) with the following text in body:
unsubscribe xsi
   

---
Unsubscribe? Mail Majordomo@(protected) with the following text in body:
unsubscribe xsi


 






<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE></TITLE>
<META http-equiv=Content-Type content=text/html;charset=ISO-8859 (See http://ISO-8859.ora-code.com)-1>
<META content="MSHTML 6.00.2737.800" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>really?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>thanks for sharing.....</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>good one.</FONT></DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT:
#000000 2px solid; MARGIN-RIGHT: 0px">
 <DIV style="FONT: 10pt arial">-- -- Original Message -- -- </DIV>
 <DIV
 style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
 <A title=guy@(protected) href="mailto:guy@(protected)">Guy Rabiller</A>
 </DIV>
 <DIV style="FONT: 10pt arial"><B>To:</B> <A title=XSI@(protected)
 href="mailto:XSI@(protected)">XSI@(protected)</A> </DIV>
 <DIV style="FONT: 10pt arial"><B>Sent:</B> Tuesday, June 01, 2004 5:12
PM</DIV>
 <DIV style="FONT: 10pt arial"><B>Subject:</B> Re: Benchmarking C++
 operators</DIV>
 <DIV><BR></DIV>On factor to enhance the speed of any operator, is to not
query
 the ports and parameters with string names.<BR>Rather use indexes with
 GetPortAt and GetParameters.<BR>You might get considerable speed
 enhancement.<BR><PRE class=moz-signature cols="$mailwrapcol">--
guy rabiller | 3d technical director @ LaMaison</PRE><BR><BR>Felix Gebhardt
 wrote:<BR>
 <BLOCKQUOTE cite=mid006401c447e9$3ae6c1d0$8202a8c0@(protected) type="cite"><PRE
wrap="">Luc-Eric Rousseau wrote:
 </PRE>
   <BLOCKQUOTE type="cite"><PRE wrap="">right, QueryPerformanceCounter is what
we
use for mesuring an operator's performance.
   </PRE></BLOCKQUOTE><PRE wrap=""><!---->
Now I only need to actually HAVE your operator's performance. But hey, at
least we use the same timer ;)

Thanks for telling,
Felix



 </PRE>
   <BLOCKQUOTE type="cite"><PRE wrap="">-- --Original Message-- --
From: <A class=moz-txt-link-abbreviated href="mailto:owner-xsi@(protected)"
>owner-xsi@(protected)</A> [<A class=moz-txt-link-freetext href="mailto:owner
-xsi@(protected)">mailto:owner-xsi@(protected)</A>]On Behalf
Of Felix Gebhardt
Posted At: Tuesday, June 01, 2004 10:08 AM
Posted To: xsi
Conversation: Benchmarking C++ operators
Subject: Re: Benchmarking C++ operators


Hi Daniel, thanks for helping out,

I already had a look at VTune. Like you said. It's way overdosed for my
purpose and too expensive to setup. I will have a look at the MSVC option
but I also found something interesting on codeproject.
<A class=moz-txt-link-freetext href="http://www.codeproject.com/cpp
/precisetimer.asp">http://www.codeproject.com/cpp/precisetimer.asp</A>


If there is anything else, keep em coming,
Felix




Daniel Bachler wrote:
   </PRE>
     <BLOCKQUOTE type="cite"><PRE wrap="">Well there is Intels Vtune, but it's
quite expensive (although I think
that there is a trial version available) and it can be a bit tough to set
up so that it returns some usefull information. MSVC has some kind of
profiler of its own IIRC, but without any graphical representation or
anything fancy. And, last but not least, you can of course take
timestamps yourself everytime you operator gets called and everytime it
returns and measuring that time. If it's something simple I would first
try the last trick, it's quite fast to setup and very precise, as the
time you loose on profiling is really negligible. If you want to take it
a step further you can store an array of simple structures containing
last starttime and amount of time in that block, then write two small
function, like this: (C++ style pseudocode)

Void StartBlock(int blockIndex)
{
m_ProfilerStructures[blockIndex].m_Starttime = gettime();
}

Void EndBlock(int blockIndex)
{
m_ProfilerStructures[blockIndex].m_ElapsedTime += gettime() -
m_ProfilerStructures[blockIndex].m_Startime();
}

You can then use it like this:

StartBlock(INIT);
Initialize();
EndBlock(INIT);
StartBlock(MAIN);
DoStruff();
EndBlock(MAIN);

Daniel

     </PRE>
       <BLOCKQUOTE type="cite"><PRE wrap="">-- --Original Message-- --
From: <A class=moz-txt-link-abbreviated href="mailto:owner-xsi@(protected)"
>owner-xsi@(protected)</A>
[<A class=moz-txt-link-freetext href="mailto:owner-xsi@(protected)">mailto
:owner-xsi@(protected)</A>] On Behalf Of Felix Gebhardt
Sent: Tuesday, June 01, 2004 2:22 PM
To: <A class=moz-txt-link-abbreviated href="mailto:XSI@(protected)">XSI
@(protected)</A>
Subject: Benchmarking C++ operators

Hi all,

does anyone happen to have an advise on what's the best way
to benchmark
compiled operators? In VBS I just would take a time snapshot
but it's not
too precise. How to nail it down better in C++? Any simple
but precise way
or free and easy to use analyzer/profiler?

Suggestions greatly appreciated,
Felix
       </PRE></BLOCKQUOTE></BLOCKQUOTE><PRE wrap="">---
Unsubscribe? Mail <A class=moz-txt-link-abbreviated href="mailto:Majordomo
@(protected)">Majordomo@(protected)</A> with the following text in body:
unsubscribe xsi
   </PRE></BLOCKQUOTE><PRE wrap=""><!---->
---
Unsubscribe? Mail <A class=moz-txt-link-abbreviated href="mailto:Majordomo
@(protected)">Majordomo@(protected)</A> with the following text in body:
unsubscribe xsi


 </PRE></BLOCKQUOTE><BR><PRE class=moz-signature cols="$mailwrapcol"></PRE><BR
></BLOCKQUOTE></BODY></HTML>