Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » Epsilon Profiling Tools(Can i get the execution time as a rational number)
Epsilon Profiling Tools [message #1773591] Fri, 29 September 2017 18:17 Go to next message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 152
Registered: October 2014
Senior Member
Hi,

I notice that the execution time in Epsilon profiling always gives integer numbers ,so can i change the format of the execution time to be like 0.1 or 0.2 because i got 0 ms for the small operations .I am assuming that the execution time for such case is between 0-0.5 .


Thanks
Taghreed
Re: Epsilon Profiling Tools [message #1773626 is a reply to message #1773591] Sun, 01 October 2017 14:13 Go to previous messageGo to next message
Antonio Garcia-Dominguez is currently offline Antonio Garcia-DominguezFriend
Messages: 470
Registered: January 2010
Senior Member
Yes, Epsilon takes times in milliseconds:

https://git.eclipse.org/c/epsilon/org.eclipse.epsilon.git/tree/plugins/org.eclipse.epsilon.profiling/src/org/eclipse/epsilon/profiling/Stopwatch.java#n21

We could take times in nanoseconds, but in practice that doesn't work so well for small tasks:

* The resolution of the timer is OS-dependant (you might not get times at the nanosecond level anyway).
* For very small tasks, anything else going on in your computer will distort the results too much.
* The just-in-time recompilation of the Java runtime will also distort results.

Usually I'd recommend using the Epsilon profiler against larger models rather than trying to measure very small tasks. For that, you would need a proper microbenchmarker (like JMH for Java) that allows you to "warm up" the JIT recompiler.

Do you have access to larger models, or can you at least run the same operation repeatedly a considerable number of times in the same execution of the Epsilon script?

Also, if you really want to do microbenchmarking, you should probably check a few articles on the underlying complexities:

https://shipilev.net/blog/2014/nanotrusting-nanotime/

[Updated on: Sun, 01 October 2017 14:16]

Report message to a moderator

Re: Epsilon Profiling Tools [message #1773661 is a reply to message #1773626] Mon, 02 October 2017 14:07 Go to previous message
taghreed altamimi is currently offline taghreed altamimiFriend
Messages: 152
Registered: October 2014
Senior Member
Hi Antonio,
Thanks for your prompt reply.I tried to run the timer for larger operations and i got the result.

Thanks,
Taghreed.
Previous Topic:Sharing UML-RT transformation scripts
Next Topic:Combine two projects in one model
Goto Forum:
  


Current Time: Wed Jan 17 07:41:28 GMT 2018

Powered by FUDForum. Page generated in 0.01749 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software