Hi Gaëtan, Thank you for your answer!
I did look at this test and it counts the number of context switches between two threads of the same priority in one second. What I want is something more abstract (any thread, any priority). To reformulate my question, let's assume I have two threads. It doesn't matter what they are doing. One of the threads will be interrupted by the other and a context switch will occur. What I want to know is how much time is spent in the context switching. I don't think this is possible at the application-level. Regards, Julien ________________________________ De : Gaëtan Harter <gaetan.har...@fu-berlin.de> Envoyé : jeudi 15 novembre 2018 17:28:16 À : devel@riot-os.org; Julien Gomez Objet : Re: [riot-devel] Compute the time elapsed when switching between two threads Hi Julien, I think this test should be doing what you want, I did not look at it just knew it existed. https://github.com/RIOT-OS/RIOT/tree/master/test/bench_thread_yield_pingpong Regards, Gaëtan - cladmi On 15.11.18 16:41, Julien Gomez wrote: > Hello fellow developers ! > > I have a simple question: How one could compute the time elapsed when > switching from thread A to thread B? > > Any advice or lead is welcome! > > Regards, > Julien > > > _______________________________________________ > devel mailing list > devel@riot-os.org > https://lists.riot-os.org/mailman/listinfo/devel >
_______________________________________________ devel mailing list devel@riot-os.org https://lists.riot-os.org/mailman/listinfo/devel