linguini1 commented on code in PR #17011: URL: https://github.com/apache/nuttx/pull/17011#discussion_r2440935185
########## boards/sim/sim/sim/configs/vncserver/defconfig: ########## @@ -12,6 +12,7 @@ CONFIG_ARCH_BOARD_SIM=y CONFIG_ARCH_CHIP="sim" CONFIG_ARCH_SIM=y CONFIG_BOARD_LATE_INITIALIZE=y +CONFIG_BOARD_LOOPSPERMSEC=0 Review Comment: > see this pr: #14450 Ah, that makes more sense. So it was removed before I had unified the `up_delay` functions. That PR removes the "accurate" implementation in favour of always using the coarse implementation though, so that means after this PR was merged, the simulator would never respect delays at all since `LOOPSPERMSEC` is always set to 0 on sim if its not missing. So currently, `LOOPSPERMSEC` on sim causes it to never respect delays at all. Not sure how we haven't seen anything fail on sim due to that change, but it seems to be working. I guess my options here are to either restore the `arch_alarm.c` implementation with something that prevents architectures that use it from using coarse delays, or create a sim-specific `up_delay` definition which maybe uses the new `nxsched_sleep` from #17200? I don't think it's possible to find a good `LOOPSPERMSEC` value on sim since I would guess it varies widely depending on the host machine hardware. Do you have any suggestions on what would be the best option? -- 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]
