Add selected functions to optimization for faster interrupt handling
This commit is contained in:
parent
e2c2be6e30
commit
ea3d0121cc
@ -46,7 +46,7 @@ uint64_t systick_get_global_tick()
|
||||
return global_tick_ms;
|
||||
}
|
||||
|
||||
bool systick_ticks_have_passed(uint64_t start_timestamp, uint64_t ticks)
|
||||
bool __attribute__((optimize("O3"))) systick_ticks_have_passed(uint64_t start_timestamp, uint64_t ticks)
|
||||
{
|
||||
uint64_t end_timestamp = start_timestamp + ticks;
|
||||
uint64_t current_timestamp = systick_get_global_tick();
|
||||
@ -73,7 +73,7 @@ bool systick_ticks_have_passed(uint64_t start_timestamp, uint64_t ticks)
|
||||
*
|
||||
* @warning For calling cyclic functions use separate timers/flags and don't spoil this function
|
||||
*/
|
||||
void SysTick_Handler()
|
||||
void __attribute__((optimize("O3"))) SysTick_Handler()
|
||||
{
|
||||
/* Increase tick counters */
|
||||
wait_tick_ms++;
|
||||
|
Loading…
Reference in New Issue
Block a user