xiaoxiang781216 commented on PR #12320:
URL: https://github.com/apache/nuttx/pull/12320#issuecomment-2119085814

   > @xiaoxiang781216 I removed `volatile uintptr_t` usage in `nx_start.c` and 
the `out-bounds` warnings come back for `sim/sotest` as per the [CI log from 
Linux(sim-02)](https://github.com/apache/nuttx/actions/runs/9136422466/job/25125242332).
   > 
   > Please let me know if there are better ways or I shall add them back with 
comments like below:
   > 
   > ```c
   >    {
   > -      tcb = (FAR struct task_tcb_s *)&g_idletcb[i];
   > +      /* To shut up gcc warnings for `sim/sotest` */
   > +
   > +      volatile uintptr_t p = (uintptr_t)&g_idletcb[i];
   > +      tcb = (FAR struct task_tcb_s *)p;
   > ```
   
   why not change type of tcb to `FAR struct tcb_s *` and remove the cast?


-- 
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: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to