anchao commented on code in PR #17065:
URL: https://github.com/apache/nuttx/pull/17065#discussion_r2385532094


##########
sched/sched/sched_timerexpiration.c:
##########
@@ -424,16 +427,22 @@ static clock_t nxsched_timer_start(clock_t ticks, clock_t 
interval)
       interval = interval <= (CONFIG_TIMER_ADJUST_USEC / USEC_PER_TICK) ? 0 :
                  interval - (CONFIG_TIMER_ADJUST_USEC / USEC_PER_TICK);
 
-#ifdef CONFIG_SCHED_TICKLESS_ALARM
+#ifdef CONFIG_HRTIMER
+    ret = hrtimer_start(&g_hrtimer_systick_timer,
+                        NSEC_PER_TICK * (ticks + interval),

Review Comment:
   Nuttx was originally designed as a tick-based framework with a simple and 
efficient architecture, making it suitable for use on lower-frequency CPUs like 
the Cortex-M. HRtimers are merely an alternative.
   
   Also, we cannot switch all timer systems to HRtimers, as this would degrade 
overall system performance. HRtimers are only suitable for high-frequency CPUs 
with real-time requirements.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to