https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115689
--- Comment #3 from kargls at comcast dot net --- The code you posted is standard conforming, and when compiled, executes as expected. My point is that the program is exiting. The operate system will reap the process and reclaim the memory. Valgrind need not warn about this. It is just noise. It is not a memory leak. If anything it is poor programming on the part of the person that wrote the code, and arguably a bug the code. If the valgrind nonsense bothers a programmer, then the programmer can do the explicit deallocation. > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115689 > > --- Comment #2 from Jerry DeLisle <jvdelisle2 at gmail dot com> --- > Well I do not know about how all the hooks work but this is with the following > configure: > > ../trunk/configure --prefix=/home/jerry/dev/usr > --enable-languages=c,c++,fortran --enable-libgomp --disable-bootstrap > --enable-valgrind-annotations > > Enabling the valgrind annotations should give fairly accurate results. I do > not > know what you get on FreeBSD OS. I was using Fedora 40 OS. >