Is 23us from Queue Writing to Queue Reading normal?

shalongbasi wrote on Wednesday, May 06, 2015:

I just modified a demo program in which one task writing to the Queue and another task reading the Queue to evaluate the performance of freertos. I make the program toggling two different IO pins when writing and reading are finished. It takes about 22us from writing task to reading task. Is this normal for Freertos? feels like it should go faster than this with a 80MHz/105MDMIPS microcontroller.

rtel wrote on Thursday, May 07, 2015:

If I understand correctly you are measuring the time between one task writing data to a queue, a task being unblocked, the scheduler selecting the task as the highest priority task, switching to the task, then the task reading from a queue - 23us might be reasonable, or at least, not unreasonable.

Are you calling portYIELD_FROM_ISR() (or maybe portEND_SWITCHING_ISR(), I forget which is implemented on the PIC32, maybe both) at the end of the interrupt? Do you have compiler optimisation on?