Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » eTrice » Some Performance Data(Some Performance Data on XMC4500 Microcontroller)
Some Performance Data [message #1697267] Tue, 02 June 2015 20:20 Go to next message
Thomas Jung is currently offline Thomas JungFriend
Messages: 8
Registered: May 2015
Junior Member
I did some measurements to check the runtime performance. Here are the results:
Testplattform:
XMC4500 (ARM Cortex M4 from Infineon, 120Mhz), GCC (Dave4, Optimazation -O0), no Operating System.
PingPong Model.
12,35 seconds for 1000000 messages => 81000Msgs/sec => 12us/Msg
with optimazation -O3:
4,19 seconds for 1000000 messages => 4,2us/Msg

Thomas
Re: Some Performance Data [message #1697271 is a reply to message #1697267] Tue, 02 June 2015 20:31 Go to previous messageGo to next message
Thomas Schuetz is currently offline Thomas SchuetzFriend
Messages: 31
Registered: January 2010
Member
Excellent,
until now we have not had any performance issues, but it is good to have numbers.

Could you run the test also on your Windows machine (one thread and two threads) to have the comparison to a much bigger cpu?

And it would also be helpful to have some numbers about RAM/ROM usage for runtime and model elements.

Thomas

Re: Some Performance Data [message #1697483 is a reply to message #1697271] Thu, 04 June 2015 10:00 Go to previous messageGo to next message
Thomas Jung is currently offline Thomas JungFriend
Messages: 8
Registered: May 2015
Junior Member
Hello Thomas,

i am not sure if it makes sense to run it on windows, because you can never be sure that something interrupts you.

But i did some measurements with the same model on the same plattform on a multi threaded environment (FreeRTOS). Optimazation level -O3.
The results are:
Both aktors on the same thread: 18us/msg
The two aktors on different threads: 40us/Msg

The results are expectable and still very good from my perspective. We have to protect the queue with a mutex even if we run on the same thread. This causes the overhead in the first case. If we run the aktors on different threads we additionally have the thread switch for each message. This needs additional time.
As an idea for optimazation we could think about a second queue for thread internal communication. This would eliminate the overhead in the first case but costs some more memory.


Concerning RAM/ROM i checked the map file and found the following numbers (everything for optimazation level -O3):

ROM:
Code for the single threaded runtime (including the platform specific part, without any logging instrumentation): 0x4CC => 1228 Byte
This is the constant part of the code.

Code for the Application: 0x300 => 768 Byte
The application consits of two Aktors with a simple FSM each. Most of the code are constant data because we map all the constant infrstructure to ROM/Flash.

RAM:
The singe threaded runtime needs just 16Bytes data.
(8 Bytes to store the time, one pointer to hold the execute function (4 Bytes on our 32Bit machine), one pointer to hold the timer function).

The application is basically dominated from the queue size. I configured 32 messages with 10 Bytes each. => 320 Bytes for the queue. The minimum message size is 8Bytes.
For each Aktor we need one pointer to constant data (4 Bytes in our case), 2Bytes to hold the state for the FSM + 2Bytes for each FSM hierarchy level.
My example needs arround 340Bytes.

We allready know that RAM consupmtion as well as footprint is really competitive, because we are able to run a small modell on a MSP430G2553 with 16K Flash and 512Byte RAM.

As i mentioned, the numbers are for optimazation -O3. For a debug build with -O0 you can double the code to be on the save side. The RAM size will remain the same.

The numbers are related to the eTrice generated Code. The Dave generated code as well as startup and Library code is not included.

If somebody wants to have the testmodels for verification, please let me know.

Thomas
Re: Some Performance Data [message #1697599 is a reply to message #1697267] Fri, 05 June 2015 09:30 Go to previous message
Thomas Schuetz is currently offline Thomas SchuetzFriend
Messages: 31
Registered: January 2010
Member
Thanks - could you add those numbers to the documentation for 0.5. I will create a chapter for the the info about resource consumption.

Thomas
Previous Topic:eTrice works already with Mars
Next Topic:[announce] eTrice 0.5.0 first milestone build
Goto Forum:
  


Current Time: Thu Apr 25 10:21:36 GMT 2024

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

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

Back to the top