huojianchaoyy opened a new pull request, #4125:
URL: https://github.com/apache/nuttx-apps/pull/4125

   *Note: Please adhere to [Contributing 
Guidelines](https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md).*
   
   ## Summary
   
   - **system/debugpoint: prevent optimizations to ensure debugpoints are 
triggered** (from Xiaomi Vela): `test_function()` and `test_data()` run the 
access that should hit the breakpoint or the watchpoint and then check 
`triggered`, which the debug exception handler sets. Nothing stopped the 
compiler from moving the check ahead of a plain memory access; `UP_DSB()`, a 
memory barrier that is also a compiler barrier, now surrounds each access that 
should fire. The subject is shortened from "prevent compiler optimizations to 
..." to fit in 80 characters.
   
   One commit first: **system/debugpoint: fix the indentation of 
parse_options()**, existing nxstyle errors in `debug.c`, which this PR touches. 
No functional change.
   
   ## Impact
   
   - `debugpoint` self-test only.
   
   ## Testing
   
   Host: Ubuntu 22.04 x86_64, Arm GNU Toolchain 13.2.rel1, CMake 3.23 + Ninja 
1.10, QEMU 10.2.1. nuttx master c8907860837, apps base 8ff87439bf4.
   
   `./tools/checkpatch.sh -c -u -m -g HEAD~2..HEAD` (nuttx master's) passes.
   
   Builds with `SYSTEM_DEBUGPOINT`: `qemu-armv7a:gdbstub` (CMake and Make) and 
`mps3-an547:gdbstub` (CMake), no new warning.
   
   Not tested at run time: QEMU does not provide the debug units (on 
`mps3-an547`, registering a breakpoint fails with -28 before and after this 
PR), and no hardware was at hand.
   


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