Skip to content

Commit

Permalink
Import Geant4 10.6.0.beta source tree
Browse files Browse the repository at this point in the history
  • Loading branch information
gcosmo committed Jun 28, 2019
1 parent 28a7070 commit d0f9119
Show file tree
Hide file tree
Showing 1,056 changed files with 83,482 additions and 66,474 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX
# the same form.
project(Geant4)
set(${PROJECT_NAME}_VERSION_MAJOR 10)
set(${PROJECT_NAME}_VERSION_MINOR 5)
set(${PROJECT_NAME}_VERSION_PATCH 1)
set(${PROJECT_NAME}_VERSION_MINOR 6)
set(${PROJECT_NAME}_VERSION_PATCH 0)
set(${PROJECT_NAME}_VERSION "${${PROJECT_NAME}_VERSION_MAJOR}.${${PROJECT_NAME}_VERSION_MINOR}.${${PROJECT_NAME}_VERSION_PATCH}")

# - Prepend our own CMake Modules to the search path
Expand Down
685 changes: 685 additions & 0 deletions ReleaseNotes/Beta4.10.6-1.txt

Large diffs are not rendered by default.

168 changes: 168 additions & 0 deletions ReleaseNotes/Patch4.10.4-3.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@

Geant4 10.4 - patch-03 Release Notes
------------------------------------

8 February 2019

List of fixes included in this public patch since the public release 10.4.p02:

o Configuration:
-------------
+ CMake:
o Corrected URLs for data installation to use https; added -L flag to curl
to follow redirects when accessing a dataset URL.
o Geant4MakeRules_cxx.cmake: added -DGL_SILENCE_DEPRECATION to
CMAKE_CXX_FLAGS_INIT for clang to silence GL deprecation compilation
warnings on MacOS 10.14 Mojave.
+ GNUMake:
o Fixed setting of G4RUNPATHOPTION in Darwin/Linux-clang/g++ and binmake.cmk.
Addressing problem report #2086.
o Cleanup settings for GL in Darwin-clang.gmk and Darwin-g++.gmk.
Added -DGL_SILENCE_DEPRECATION to CPPFLAGS to silence GL deprecation
compilation warnings on MacOS 10.14 Mojave.

o Analysis:
--------
+ Fixed a deadlock issue with G4RootPNtupleManager where the mutex
was locked before being passed to Root.
+ Fixed compilation warnings on gcc-8.1.0.

o Geometry:
--------
+ management:
o Use reverse_iterator in G4SolidStore::DeRegister() in order to speedup
partial deregistration on setups with many solids instances.
o G4Region: added possibility to disable search in the tree in
AddRootLogicalVolume() for speeding up process in complex flat geometries.

o Global:
------
+ G4PhysicsVector, G4Physics2DVector: fixed possible out-of-bound access
in FindBin() method. Addressing problem report #2087.
+ Updated date and version for 10.4.p03.

o Interfaces:
----------
+ G4Xt: fixed compilation warnings for casts on gcc-8.1.
+ Fixed compilation warnings for not used return parameters.

o Persistency - gdml
------------------
+ Clear auxiliary map information in G4GDMLReadStructure::Clear().
Addressing problem report #2064.
+ Added stripping of invalid characters for names generation in writer classes
to prevent invalid NCName strings in exported GDML files. Adopt properly
stripped generated strings for exporting names of optical surfaces.

o Processes - Electromagnetic:
---------------------------
+ dna:
o Fixed header guards in G4ITFinder and G4AllITFinder.
Addressing problem report #2084.
+ standard:
o G4GoudsmitSaundersonTable: fixed gcc-8.1.0 compilation warnings.
+ utils:
o G4EmElementSelector: optimisation of element selection for compound
materials.
+ xrays:
o G4Cerenkov, G4Scintillation: correctly reset number of photons
to 0 each step. Addressing problem report #2056.
Added protection against infinite loops due to very small steps.
Addressing problem report #1992.

o Processes - Hadronic:
--------------------
+ management:
o G4HadronicProcess: added check if secondary particle is on the mass
shell; if its mass differ from the PDG mass more for 1.5 MeV then mass
is forced to the mass shell, energy conserved, but momentum is changed.
Use correct return type when calling CheckResult() from PostStepDoIt():
fixes case when the value of pointer 'result' does not get properly
reset to NULL in case a non-conservation is detected, thus "bad"
interaction does not get re-sampled.
Fixed compilation warnings on gcc-8.1.0 regarding catching polymorphic
type by value, instead of by reference.
o G4HadronicProcess, G4VLeadingParticleBiasing, G4HadLeadBias: fixed
compilation warning with gcc-7.
+ models/binary_cascade
o G4GeneratorPrecompoundInterface: fixed printout typo.
+ models/cascade:
o G4GDecay3: fixed problem reported by CMS due to wrong kinematics in
the final state by removing loop check; adding protection for low value
of mother mass.
+ models/de_excitation:
o G4LevelReader: fixed initialisation of 'fAlphaMax' from 1.e+6 to 1.e+15;
needed for correct IC probability of some isotopes.
Addresses problem reports #1986 and #2076, by change of handling of
internal conversion data.
+ models/particle_hp
o G4ParticleHPCaptureFS::ApplyYourself(): Lorentz boost of neutron into
target frame was backwards; reversed it. Also replaced SetDefinition()
with SetDefinitionAndUpdateE(). Addresses problem report #1919.
o Fixed definition of singletons for G4ParticleHPManager and
G4ParticleHPThreadLocalManager and some code cleanup.
Made G4ParticleHPThreadLocalManager a G4ThreadlLocalSingleton to avoid
memory leaks generated each time a thread creates the instance.
o Fixed bug for double allocation of G4ParticleHPReactionWhiteBoard in
G4ParticleHPThreadLocalManager::OpenReactionWhiteBoard().
o G4ParticleHPElementData: removed unnecessary inheritance from
G4HadronicCrossSection.
o Fixed incorrect sampling of isotropic distribution.
Addressing problem report #1745.
o Fixed gamma level mismatch in G4ParticleHPInelasticCompFS.
Not a complete fix because gamma data comes from ENSDF and does not
necessarily match excitations in ENDF.
Addressing problem report #1789.
o Fixed memory leaks in G4ParticleHPContEnergyAngular::Sample() and
G4ParticleHPContAngularPar::cacheInit().
Addressing problem report #2026.
o G4ParticleHPElasticFS::ApplyYourself(): use correct reference frames for
calculation of projectile and target momenta. Correction made for cases
when cos(Theta) is given in lab frame and in center of momentum frame.
Partial fix of momentum non-conservation for problem report #1918.
o Fixed potential leaks in G4ParticleHPPhotonDist, G4ParticleHPContAngularPar
and G4ParticleHPFinalState for use of pointers cached in G4Cache.
o G4ENDFTapeRead, G4FissionProductYieldDist: fixed compilation warnings
on gcc 8.1.0, regarding catching polymorphic type by value, instead of
by reference.
o Minor code cleanup and formatting.
+ models/parton_string/diffraction
o G4FTFAnnihilation: fix to get flat cos(theta) and phi distributions for
antiproton annihilation at rest.
+ models/rpg
o G4RPGAntiKZeroInelastic, G4RPGInelastic: fixed compilation warnings on
gcc-8.1.0, regarding catching polymorphic type by value, instead of by
reference.
+ processes:
o G4HadronElasticProcess, G4NeutrinoElectronProcess: fixed compilation
warnings on gcc 8.1.0, regarding catching polymorphic type by value,
instead of by reference.
+ stopping:
o G4HadronStoppingProcess, G4MuonicAtomDecay: fixed compilation warnings
on gcc 8.1.0, regarding catching polymorphic type by value, instead of
by reference.

o Processes - Scoring:
-------------------
o G4ParallelWorldProcess: fixed track velocity of optical photons for the
first step in a layered mass geometry.

o Examples:
--------
+ extended/fieldBlineTracer:
o Fixed compilation error for missing header inclusion.

----------------------------------------------------------------------------

Technical Notes
---------------

o This patch should be applied on top of release 10.4 or 10.4.p01 or p02.
o Technical notes distributed for release 10.4 are also applicable and
valid for this patch.

The code and rebuilt binary libraries for release 10.4.p03 are available
through our "Download" Web page.

Please refer to the Geant4 User Documentation for further information about
using Geant4.
36 changes: 35 additions & 1 deletion cmake/History
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,41 @@ add this in the documentation for the changed file as [BUGFIX #BUGNUMBER].

----------------------------------------------------------

21st December 2018 - Makoto Asai (cmake-V10-04-28)
6th June 2019 - Ben Morgan (cmake-V10-05-05)
- Remove G4FPE_DEBUG from Debug build mode
- Not appropriate for basic debug and incompatible with Qt
- Provide new "Debug_FPE" build mode which copies Debug mode and
appends -DG4FPE_DEBUG to allow continued use without clashing
with common primary modes.

24th May 2019 - Gunter Folger (cmake-V10-05-04)
- Switch to G4PARTICLEXS 2.0

14th May 2019 - Ben Morgan (cmake-V10-05-03)
- Promote always required -D flags for VecGeom replacements to fixed
#define/undef flags in a header
- See geommng-V10-05-05, G4GeomTypes/G4GeomConfig.hh
- Set CMake variables for G4GEOM_USE_... parameters as configured
- Retain add_definitions for VecGeom until it supports usage requirements
- Update XXHelpers scripts for generating GNUmake/pkg-config/CMake files

8th February 2019 - Ben Morgan (cmake-V10-05-02)
- DEV-250: Promote global, always required, -D flags to fixed #define/undef
in new G4GlobalConfig.hh header:
- G4USE_STD11
- G4MULTITHREADED
- G4_STORE_TRAJECTORY
- G4VERBOSE
- GEANT4_USE_TIMEMORY
- Remove use of add_definitions of CMAKE_CXX_FLAGS to set these in Geant4
and client scripts
- Used by global-V10-05-02

7th February 2019 - Ben Morgan (cmake-V10-05-01)
- Remove obsolete GEANT4_BUILD_MUONIC_ATOMS_IN_USE option
and associated configuration/compiler flags.

21st December 2018 - Makoto Asai (cmake-V10-05-00)
- Modules/Geant4OptionalComponents.cmake:
- Template/Geant4Config.cmake.in:
Add GEANT4_USE_SMARTSTACK
Expand Down
46 changes: 12 additions & 34 deletions cmake/Modules/G4BuildSettings.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,15 @@ include(IntelCompileFeatures)
#
if(NOT WIN32)

#.rst:
# - ``Debug_FPE``
# For debugging with full Floating Point Exception checking
#
set(CMAKE_CXX_FLAGS_DEBUG_FPE "${CMAKE_CXX_FLAGS_DEBUG_FPE_INIT}"
CACHE STRING "Flags used by the compiler during Debug_FPE builds"
)
mark_as_advanced(CMAKE_CXX_FLAGS_DEBUG_FPE)

#.rst:
# - ``TestRelease``:
# For trial production and extended testing. It has verbose
Expand Down Expand Up @@ -110,18 +119,19 @@ if(NOT CMAKE_CONFIGURATION_TYPES)
if(NOT CMAKE_BUILD_TYPE)
# Default to a Release build if nothing else...
set(CMAKE_BUILD_TYPE Release
CACHE STRING "Choose the type of build, options are: None Release TestRelease MinSizeRel Debug RelWithDebInfo MinSizeRel Maintainer."
CACHE STRING "Choose the type of build, options are: None Release TestRelease MinSizeRel Debug Debug_FPE RelWithDebInfo MinSizeRel Maintainer."
FORCE
)
else()
# Force to the cache, but use existing value.
set(CMAKE_BUILD_TYPE "${CMAKE_BUILD_TYPE}"
CACHE STRING "Choose the type of build, options are: None Release TestRelease MinSizeRel Debug RelWithDebInfo MinSizeRel Maintainer."
CACHE STRING "Choose the type of build, options are: None Release TestRelease MinSizeRel Debug Debug_FPE RelWithDebInfo MinSizeRel Maintainer."
FORCE
)
endif()
else()
# Multimode tools like VS, Xcode
list(APPEND CMAKE_CONFIGURATION_TYPES Debug_FPE)
list(APPEND CMAKE_CONFIGURATION_TYPES TestRelease)
list(APPEND CMAKE_CONFIGURATION_TYPES Maintainer)
list(REMOVE_DUPLICATES CMAKE_CONFIGURATION_TYPES)
Expand Down Expand Up @@ -200,9 +210,6 @@ endif()
# An example of where a workaround is needed
# Rest of concurrency a library implementation feature

# Add Definition to flags for temporary back compatibility
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DG4USE_STD11")

# Hold any appropriate compile flag(s) in variable for later export to
# config files. Needed to support clients using late CMake 2.8 where compile features
# are not available.
Expand Down Expand Up @@ -261,7 +268,6 @@ if(GEANT4_BUILD_MULTITHREADED)

# Set Defs/Compiler Flags
# TODO: Migrate def to header
add_definitions(-DG4MULTITHREADED)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${GEANT4_MULTITHREADED_CXX_FLAGS}")
endif()

Expand All @@ -280,11 +286,6 @@ option(GEANT4_BUILD_STORE_TRAJECTORY
ON)
mark_as_advanced(GEANT4_BUILD_STORE_TRAJECTORY)

# TODO: Migrate this to header
if(GEANT4_BUILD_STORE_TRAJECTORY)
add_definitions(-DG4_STORE_TRAJECTORY)
endif()

#.rst:
# - ``GEANT4_BUILD_VERBOSE_CODE`` (Default: ON)
#
Expand All @@ -297,29 +298,6 @@ option(GEANT4_BUILD_VERBOSE_CODE
ON)
mark_as_advanced(GEANT4_BUILD_VERBOSE_CODE)

# TODO: Migrate this to header
if(GEANT4_BUILD_VERBOSE_CODE)
add_definitions(-DG4VERBOSE)
endif()

#.rst:
# - ``GEANT4_BUILD_MUONIC_ATOMS_IN_USE`` (Default: OFF)
#
# - Switched off by default to improve performance when not using
# Muonic Atom code. It should be switched on if the project requires
# support for Muonic Atoms.
# Mark as advanced because most users should not need to worry about it
#
option(GEANT4_BUILD_MUONIC_ATOMS_IN_USE
"Enable turning on some if statements in track and event code. Switch on if using new Muonic Atom code."
OFF)
mark_as_advanced(GEANT4_BUILD_MUONIC_ATOMS_IN_USE)

# TODO: Migrate this to header
if(GEANT4_BUILD_MUONIC_ATOMS_IN_USE)
add_definitions(-DG4MUATOMS_INUSE)
endif()

#.rst:
# - ``GEANT4_BUILD_MSVC_MP`` (Windows only, Default: OFF)
#
Expand Down
11 changes: 1 addition & 10 deletions cmake/Modules/G4ConfigureCMakeHelpers.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -64,15 +64,6 @@ set(GEANT4_THIRD_PARTY_IMPORT_SETUP )
# Externals libraries that may be present
set(GEANT4_EXTERNALS_TARGETS )

# - Stuff from Geant4LibraryBuildOptions.cmake
if(GEANT4_BUILD_STORE_TRAJECTORY)
list(APPEND GEANT4_CORE_DEFINITIONS -DG4_STORE_TRAJECTORY)
endif()

if(GEANT4_BUILD_VERBOSE_CODE)
list(APPEND GEANT4_CORE_DEFINITIONS -DG4VERBOSE)
endif()

# - Stuff from Geant4OptionalComponents.cmake
# - CLHEP
# If it's internal, add it to the externals list
Expand Down Expand Up @@ -104,11 +95,11 @@ endif()
# Compile definitions
if(GEANT4_USE_USOLIDS OR GEANT4_USE_PARTIAL_USOLIDS)
set(GEANT4_USE_USOLIDS_EITHER ON)
list(APPEND GEANT4_CORE_DEFINITIONS ${GEANT4_USOLIDS_COMPILE_DEFINITIONS})

# System USolids headers, because these do appear in Geant4's
# public interface. The library should be in the link interface
# of G4geometry (may need refinding)
list(APPEND GEANT4_CORE_DEFINITIONS ${VECGEOM_DEFINITIONS})
list(APPEND GEANT4_THIRD_PARTY_INCLUDES "${USOLIDS_INCLUDE_DIRS} ${VECGEOM_EXTERNAL_INCLUDES}")
endif()

Expand Down
9 changes: 1 addition & 8 deletions cmake/Modules/G4ConfigurePkgConfigHelpers.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -123,13 +123,6 @@ if(NOT GEANT4_BUILD_GRANULAR_LIBS AND UNIX)
set(G4_BUILTWITH_MULTITHREADING "no")
endif()

# - Muonic Atom support
if(GEANT4_BUILD_MUONIC_ATOMS_IN_USE)
set(G4_BUILTWITH_MUONIC_ATOMS "yes")
else()
set(G4_BUILTWITH_MUONIC_ATOMS "no")
endif()

# - CLHEP
if(GEANT4_USE_SYSTEM_CLHEP)
set(G4_BUILTWITH_CLHEP "no")
Expand Down Expand Up @@ -196,7 +189,7 @@ if(NOT GEANT4_BUILD_GRANULAR_LIBS AND UNIX)
list(REMOVE_DUPLICATES G4_USOLIDS_INCLUDE_DIRS)
list(REMOVE_ITEM G4_USOLIDS_INCLUDE_DIRS ${_cxx_compiler_dirs})

string(REPLACE ";" " " G4_USOLIDS_CFLAGS "${GEANT4_USOLIDS_COMPILE_DEFINITIONS}")
string(REPLACE ";" " " G4_USOLIDS_CFLAGS "${VECGEOM_DEFINITIONS}")
foreach(_dir ${G4_USOLIDS_INCLUDE_DIRS})
set(G4_USOLIDS_CFLAGS "${G4_USOLIDS_CFLAGS} -I${_dir}")
endforeach()
Expand Down
4 changes: 2 additions & 2 deletions cmake/Modules/Geant4DatasetDefinitions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ geant4_add_dataset(
# - Particle XS - replaces Neutron XS
geant4_add_dataset(
NAME G4PARTICLEXS
VERSION 1.1
VERSION 2.0
FILENAME G4PARTICLEXS
EXTENSION tar.gz
ENVVAR G4PARTICLEXSDATA
MD5SUM 17dc6c6f11db7ca81dea1c2c2b3707d2
MD5SUM bc115502d4524ef7625557d9cab355c0
)

# - PII
Expand Down
Loading

0 comments on commit d0f9119

Please sign in to comment.