Hi, praveen ab via Gcc-help writes: > Hi All, > > We are upgrading the GCC version for our existing C/C++ project. > Earlier we were using gcc 5.4 and everything was working fine.(The > application works fine even with gcc 7.4) > When trying to build the application using gcc 8.1 and above we are > observing the random crashes mostly segmentation fault. > Any suggestions on how to debug this? > > Right now I am trying the following: > Enabling the -Wall flag and trying to fix all the warnings > Using GDB to inspect memory location and variables. > > Please Suggest anything else that needs to be checked? The UB sanitizer might also prove useful to detect UB that does not necessarily result in crashes. Pass -fsanitize=undefined to enable it. I can't provide much more specific instructions, but it's quite likely that there's a good bit of UB in the code you're building, if it broke in such a regard on compiler updates. Is there a reason for using GCC 8 as opposed to newer GCC versions? Best of luck, have a great day. -- Arsen Arsenović