Hello, in candidate tag for 9.5 there is not the possibility to setup a build with cmake (except using direct command line parameters to CMAKE) to have a build with debug symbols and FPE check without optimization. This cause problems during validation, since, while the complete stack trace is present, values of variables are optimized out and debug is made much more harder. For developers, testers and for people doing release validation it is required a build type that does not contain any optimization. Validation is performed on linux, thus if this combination is not possible on all platforms we need it at least on linux. I propose to have TestReleaseDebug build type with the following options: -g -DG4DEBUG_VERBOSE -DG4FPE_DEBUG Thank you, Andrea
This is not a problem to fix, but I need an absolutely clear statement of the flags that are needed, and their platform and compiler dependencies. To clarify what is done in 9.5, for the GNU C++ compiler, we create a mode 'TestRelease'. This has flags (in addition to the core Geant4 flags): Non-Apple: -O2 -g -G4DEBUG_VERBOSE -G4FPE_DEBUG Apple : -g -G4DEBUG_VERBOSE -G4FPE_DEBUG With MSVC, the additional flags are -O2 -Zi -G4DEBUG_VERBOSE With Intel compilers, the additional flags are -O2 -g -G4DEBUG_VERBOSE From the description, it sounds like this mode is really used to validate, so perhaps 'Validation' would be a better name for the mode? Is optimization always/never/sometimes needed? There's no technical issue in fixing this other than having a clear and agreed definition of the required flags, and avoiding too many different modes. Cheers, Ben.
Is this bug still valid, and if so, please review Comment #1 and reply.
Hi. An important use case for "TestRelease" is the use for Validation. In particular my concern is on the non-Apple (i.e. Linux) -O2 option, that makes more difficult debugging in case of problems. I thus propose to drop the -O2. If it helps to reduce confusion, I agree on changing the name of the following combination of options (on all possible platforms that support it, with priority to LINUX): -DG4FPE_DEBUG -g -DG4DEBUG_VERBOSE A name like "Validation" is adequate
Thanks Andrea! I will update when there is a tag in place to implement this (likely next few weeks)
I've just proposed tag cmake-V09-05-44: """ Remove optimization in TestRelease mode (Bug #1263) Build TestRelease mode without optimization on all platforms currently supporting this mode. Remove obsolete TestReleaseDebug build mode as new TestRelease mode fully supports debug. """ The TestRelease mode should now be consistent - please let me know if this is o.k., and we can close the bug. Cheers, Ben.
Marking this as fixed, please reopen if there are still issues.