wangchdo opened a new pull request, #18002:
URL: https://github.com/apache/nuttx/pull/18002

   ## Summary
   
   This PR includes two commits:
   
   commit 1:
       Consolidate nxsched_process_timer into sched_timer.c, and introduce
       nxsched_process_tick() to improve readability and maintainability of
       the scheduler timer processing logic.
   
   commit 2:
      Add hrtimer support to drive the scheduler.
   
   ## Impact
   
   Improve scheduler timer processing logic and enable hrtimer support for 
scheduler.
   
   ## Testing
   
   **ostest passed on rv-virt:smp64 when hrtimer is enabled**
   
   ```
   NuttShell (NSH)
   nsh> 
   nsh> 
   nsh> uname -a
   NuttX 0.0.0 a8c1583552-dirty Jan 19 2026 13:12:31 risc-v rv-virt
   nsh> ostest
   
   (...)
   
   user_main: hrtimer test
   
   End of test memory usage:
   VARIABLE  BEFORE   AFTER
   ======== ======== ========
   arena     1fc0c20  1fc0c20
   ordblks         6        6
   mxordblk  1fab270  1fab270
   uordblks    10898    12080
   fordblks  1fb0388  1faeba0
   
   Final memory usage:
   VARIABLE  BEFORE   AFTER
   ======== ======== ========
   arena     1fc0c20  1fc0c20
   ordblks         1        6
   mxordblk  1fb5b30  1fab270
   uordblks     b0f0    12080
   fordblks  1fb5b30  1faeba0
   user_main: Exiting
   ostest_main: Exiting with status 0
   nsh> 
   ```
   
   **ostest passed on a2g-tc397-5v-tft:nsh when hrtimer is enabled**
   
   ```
   NuttShell (NSH)
   nsh>
   nsh>
   nsh>
   nsh> uname -a
   NuttX 0.0.0 a8c1583552-dirty Jan 19 2026 13:16:08 tricore a2g-tc397-5v-tft
   nsh>
   nsh> ostest
   
   (...)
   
   user_main: hrtimer test
   
   End of test memory usage:
   VARIABLE  BEFORE   AFTER
   ======== ======== ========
   arena       28dfc    28dfc
   ordblks         6        6
   mxordblk    1f890    1f890
   uordblks     5574     5574
   fordblks    23888    23888
   
   Final memory usage:
   VARIABLE  BEFORE   AFTER
   ======== ======== ========
   arena       28dfc    28dfc
   ordblks         1        6
   mxordblk    24208    1f890
   uordblks     4bf4     5574
   fordblks    24208    23888
   user_main: Exiting
   ostest_main: Exiting with status 0
   nsh>
   ```
   


-- 
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