xiaoxiang781216 commented on issue #274: Improve sim timer
URL: https://github.com/apache/incubator-nuttx/pull/274#issuecomment-586552455
 
 
   > Some time back, i attempted to implement a timer for the simulation using 
a host timer on a timer pthread . I ran into the same problems as I did when I 
tried to implement simulated interrupts: 
https://cwiki.apache.org/confluence/display/NUTTX/NuttX+Simulation
   > 
   
   This patch has a smaller scope: utilize the host timer to implement RTC 
get/set without arlarm support. So the pthread sync or signal handler isn't an 
issue here.
   
   > Basically, you cannot do a NuttX context switch from the context of a host 
signal handler or from host pthreads. I still have the host-based timer 
implementation and can send a tarball to anyone who is interested. It is from 
2014 and so would need some minor environmental updates.
   
   In most case, the interrupt simulate through idle thread is same as through 
pthread/signal. Only two behaviour difference from my daily use:
   1.The bad busy loop block all work in idle thread and then the simulator 
stop response
   2.Simulated interrupt always happen inside idle thread which make the cpu 
loading generate the wrong report
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to