linguini1 commented on PR #17310: URL: https://github.com/apache/nuttx/pull/17310#issuecomment-3536541706
> What's the point of fighting for performance in debug code? It's normal for debug code to have no performance. > Null pointer debug assertions are useful because they sometimes allow you to find bugs that are hard to find, like stack/buffers overflows. I remember that this type of assertions helped me to find bugs in completely unrelated parts of the kernel. > > Also I very much doubt that all architectures support null pointer detection, the first thing that comes to my mind is STM32F0 (cortex-m0). For all STM32 0x0000:0000 is the correct address, which means that by default there will be no exception even for chips with MPU. This can lead to bugs that are difficult to detect and debug. I agree. I wonder if someone could explain though why we don't need the runtime check out of debug mode? Why is the rtcb never null? -- 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]
