anchao commented on PR #13486:
URL: https://github.com/apache/nuttx/pull/13486#issuecomment-2357410844

   > The current implementation need at least 3 executions of msr/mrs 
instructions plus 4 normal instructions, making this optimization evident. 
After optimization, only a single mrs instruction is needed, with no additional 
overhead.
   
   Have you checked the assembly code? The previous implementation only reads 
the Affinity ID through MRC (1 cycle) and does not call MCR. Now your 
implementation uses MCR instruction to save the current regs with higher 
overhead than before.
   
   
   >Unfortunately, we haven't conducted tests specifically for this single 
optimization point alone.
   Instead, we've tested the entire message sending/receiving process, and each 
test incorporates multiple optimization points.
   
   Could you provide performance diagram before and after adding this commit? 
Or API level test? Why you conclude that the performance is better than before 
without any test?
   
   My concern is that MCR may perform worse than it currently does, but I'm not 
sure, could you help confirm this?


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