@nicholaswogan , a lesson some teams have learned is to use Linux and/or Windows to debug memory errors in code and then instantiate the macOS version based on portable code. This is only going by the situations in the commercial space such as with Intel oneAPI where their tool Intel Inspector for memory leaks is available on Linux and Windows but not for macOS (likely the ValGrind issue lurking behind the scenes).
If you’re feeling brave, you can consider alpha Dr Memory.
Re: uninitialized variables, you can also try with Intel oneAPI the run-time option -check uninit for uninitialized variables e.g.,
print *, x
end
C:\Temp>ifort /standard-semantics /check:uninit a.f90
Intel(R) Fortran Intel(R) 64 Compiler Classic for applications running on Intel(R) 64, Version 2021.3.0 Build 20210609_000000
Copyright (C) 1985-2021 Intel Corporation. All rights reserved.Microsoft (R) Incremental Linker Version 14.29.30038.1
Copyright (C) Microsoft Corporation. All rights reserved.-out:a.exe
-subsystem:console
a.objC:\Temp>a.exe
forrtl: severe (194): Run-Time Check Failure. The variable '_UNNAMED_MAIN$$$X' is being used in 'C:\Temp\a.f90(1,4)' without being defined
Image PC Routine Line Source
a.exe 00007FF7DD9D5609 Unknown Unknown Unknown
a.exe 00007FF7DD9D104C Unknown Unknown Unknown
a.exe 00007FF7DDA20D7E Unknown Unknown Unknown
a.exe 00007FF7DDA21100 Unknown Unknown Unknown
KERNEL32.DLL 00007FFB1BBE7034 Unknown Unknown Unknown
ntdll.dll 00007FFB1D7C2651 Unknown Unknown UnknownC:\Temp>