UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Adventurer
Adventurer
300 Views
Registered: ‎03-22-2018

Will FreeRTOS gives me better processing time?

Jump to solution

Hi

I'm having a conceptual question concerning ZedBoard baremetal vs. ZedBoard with FreeRTOS implementations. I know that FreeRTOS provides me a set of functionalities that might be very useful for some applications, but lets say I didn't need those functionalities as my application, though very computationally demanding, uses the simple C/C++ operations.

So, there is any advantage chosing FreeRTOS over baremetal concerning processing time? The same application, that doesn't make use of any FreeRTOS functionality, will run faster in FreeRTOS?

0 Kudos
1 Solution

Accepted Solutions
Observer richardbarry
Observer
263 Views
Registered: ‎04-26-2008

Re: Will FreeRTOS gives me better processing time?

Jump to solution

Like most 'will it' questions the answer is very dependent on the application.

First the cost:  An RTOS (such as FreeRTOS) is code that must be executed, so there is some overhead.  There is also a regular regular tick interrupt, but most applications have that anyway.

Then the benefit:  DEPENDING ON YOUR APPLICATION if you are able to convert a design that would otherwise use a state machine and super loop  and pollilng inputs, so a design that uses a lot of processing CPU cycles when there is nothing to do but check if there is something to do, into a completely event dirven design using the RTOS services, so a design that only uses CPU cycles when there is something to do, then you can free up a LOT of processing time, save a LOT of power (as you also can sleep when there is nothing to do), and squeeze a LOT more functionality onto the same processor. 

Of course, this is a massive oversimplification as most applications do not fit into one camp or the other but somewhere in between.

The book might help, althoug at the time of writing it is out of date...

Regards,
Richard.

+ http://www.FreeRTOS.org
The de facto standard, downloaded every 4.2 minutes during 2015.

+ http://www.FreeRTOS.org/plus
IoT, Trace, Certification, TCP/IP, FAT FS, Training, and more...
3 Replies
Highlighted
Scholar drjohnsmith
Scholar
276 Views
Registered: ‎07-09-2009

Re: Will FreeRTOS gives me better processing time?

Jump to solution
Is this a home work question ?
Any RTOS will add an overhead compared to bare metal,
so RTOS will always be worse than Bare Metal, if bare metal is done well.

But bare metal can be done real bad , real soon , whilst a RTOS keeps things moving, even with bad code.

(An RTOS is what saved the Apollo moon machine more than once)
Observer richardbarry
Observer
264 Views
Registered: ‎04-26-2008

Re: Will FreeRTOS gives me better processing time?

Jump to solution

Like most 'will it' questions the answer is very dependent on the application.

First the cost:  An RTOS (such as FreeRTOS) is code that must be executed, so there is some overhead.  There is also a regular regular tick interrupt, but most applications have that anyway.

Then the benefit:  DEPENDING ON YOUR APPLICATION if you are able to convert a design that would otherwise use a state machine and super loop  and pollilng inputs, so a design that uses a lot of processing CPU cycles when there is nothing to do but check if there is something to do, into a completely event dirven design using the RTOS services, so a design that only uses CPU cycles when there is something to do, then you can free up a LOT of processing time, save a LOT of power (as you also can sleep when there is nothing to do), and squeeze a LOT more functionality onto the same processor. 

Of course, this is a massive oversimplification as most applications do not fit into one camp or the other but somewhere in between.

The book might help, althoug at the time of writing it is out of date...

Regards,
Richard.

+ http://www.FreeRTOS.org
The de facto standard, downloaded every 4.2 minutes during 2015.

+ http://www.FreeRTOS.org/plus
IoT, Trace, Certification, TCP/IP, FAT FS, Training, and more...
Adventurer
Adventurer
234 Views
Registered: ‎03-22-2018

Re: Will FreeRTOS gives me better processing time?

Jump to solution

Hi,

Thanks for the answers. I'm doing a personal project and wanted some insights abou the advantages between baremetal and freeRTOS, that's why I asked.

0 Kudos