wangchdo commented on PR #17573:
URL: https://github.com/apache/nuttx/pull/17573#issuecomment-3701570489

   > @anchao @wangchdo I have serious doubts about your professionalism.
   > 
   > > @wangchdo's HRTimer implementation has **fundamental functional 
correctness issues. It violates the ownership invariant of hrtimer**: that only 
one reader/writer can use the hrtimer object at a time. This violation makes it 
prone to issues in SMP scenarios, as I have consistently pointed out over and 
over again. Simple modifications like reference counting can not fix this 
implementation at all.
   > 
   > Why are you allowing such a functional incorrect code to be merged into 
the master branch. Isn’t this simply a case of factional bias clouding 
judgment? Please check this, thanks. [#17675 
(comment)](https://github.com/apache/nuttx/pull/17675#issuecomment-3698712790)
   
   @Fix-Point 
   This PR addresses the SMP corner cases you mentioned. Could you please take 
a look?
   I propose this solution for the following reasons:
   1. It allows separate optimization paths for SMP and non-SMP, leaving room 
for extreme performance and strong determinism in both cases.
   2. It provides clean, easy-to-uyse and  minimal user-facing APIs — only 
three core APIs, with no duplicated parameters:
       `hrtimer_init()`
       `hrtimer_start()`
       `hrtimer_cancel() / hrtimer_cancel_sync()`
   3. It provides basement for queue abstraction if needed.
   
   @xiaoxiang781216  I resolved you comments, could you please take a look again
   


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