[Avrora] AVRORA simulation speed
Ben L. Titzer
titzer at cs.ucla.edu
Tue Dec 20 13:34:35 PST 2005
On Dec 19, 2005, at 4:37 AM, Andrew Burnside wrote:
> Can anyone give me a rough idea how fast the Avrora simulation is?
> I saw that in some of the screenshots the actual simulation speed
> is about 300Hz, but I was unsure whether this changed depending on
> the amount of instrumentation.
The factors that affect performance mostly are:
1. Sleep behavior of program (what percentage of time the MCU is
active). This can make the difference between running at 20mhz and
2. The radio usage (mostly time in "receive" state). This can limit
the speedup for multiple node simulations and multi-processor machines.
3. Instruction mix of the program. This can make the interpreter
performance vary as much as a factor of two, especially for programs
with a large number of multi-cycle instructions.
4. Device activity (amount of accesses to various devices such as
timers, GPIO, etc). Can impact the amount of events inserted and
fired from the event queue.
5. Instrumentation applied to the program. Can affect the performance
of individual instruction executions, memory accesses, interrupts,
etc (but does not affect the behavior of the simulation).
The performance is also heavily impacted by the startup time of
Avrora; the Java VM has to load all of the classes, initialize them,
and the program has to be loaded and each simulator instance created
and initialized. Thus, for very short-running programs, the
performance for the first second of run time can be poor. For longer
running programs, this startup cost is amortized away. The "simperf"
monitor can show just how quickly the simulator gets up to speed.
The speed is also going to vary (sometimes significantly) across Java
VM versions. Avrora is more sensitive to JVM optimizations than other
Java applications because it spends a large amount of time in a small
portion of the code (the interpreter loop) and an specific
optimization technique of a particular VM could have a large effect
in such a small case.
Hope this helps,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Avrora