Commit 01e6b156 authored by Volker Springel's avatar Volker Springel
Browse files

Merge branch 'master' of gitlab.mpcdf.mpg.de:vrs/gadget4

parents d2ba21e6 e3e352d8
...@@ -243,6 +243,7 @@ SUBDIRS += logs ...@@ -243,6 +243,7 @@ SUBDIRS += logs
OBJS += logs/logs.o OBJS += logs/logs.o
INCL += logs/logs.h logs/timer.h INCL += logs/logs.h logs/timer.h
SUBDIRS += gitversion SUBDIRS += gitversion
INCL += gitversion/version.h INCL += gitversion/version.h
...@@ -260,11 +261,6 @@ OBJS += pm/pm_nonperiodic.o pm/pm_periodic.o \ ...@@ -260,11 +261,6 @@ OBJS += pm/pm_nonperiodic.o pm/pm_periodic.o \
INCL += pm/pm.h pm/pm_mpi_fft.h pm/pm_periodic.h pm/pm_nonperiodic.h INCL += pm/pm.h pm/pm_mpi_fft.h pm/pm_periodic.h pm/pm_nonperiodic.h
SUBDIRS += vectorclass
OBJS += vectorclass/instrset_detect.o
INCL +=
SUBDIRS += sort SUBDIRS += sort
OBJS += sort/peano.o OBJS += sort/peano.o
INCL += sort/peano.h sort/cxxsort.h sort/parallel_sort.h INCL += sort/peano.h sort/cxxsort.h sort/parallel_sort.h
...@@ -274,6 +270,7 @@ SUBDIRS += sph ...@@ -274,6 +270,7 @@ SUBDIRS += sph
OBJS += sph/density.o sph/hydra.o sph/init_entropy.o sph/artificial_viscosity.o OBJS += sph/density.o sph/hydra.o sph/init_entropy.o sph/artificial_viscosity.o
INCL += sph/kernel.h sph/sph.h INCL += sph/kernel.h sph/sph.h
SUBDIRS += system SUBDIRS += system
OBJS += system/pinning.o system/system.o OBJS += system/pinning.o system/system.o
INCL += system/system.h system/pinning.h INCL += system/system.h system/pinning.h
...@@ -308,6 +305,13 @@ OBJS += ngbtree/ngbtree_build.o ...@@ -308,6 +305,13 @@ OBJS += ngbtree/ngbtree_build.o
INCL += ngbtree/ngbtree.h INCL += ngbtree/ngbtree.h
ifeq (EXPLICIT_VECTORIZATION,$(findstring EXPLICIT_VECTORIZATION,$(CONFIGVARS)))
SUBDIRS += vectorclass
OBJS += vectorclass/instrset_detect.o
INCL +=
endif
ifeq (COOLING,$(findstring COOLING,$(CONFIGVARS))) ifeq (COOLING,$(findstring COOLING,$(CONFIGVARS)))
OBJS += cooling_sfr/cooling.o cooling_sfr/sfr_eos.o cooling_sfr/starformation.o OBJS += cooling_sfr/cooling.o cooling_sfr/sfr_eos.o cooling_sfr/starformation.o
INCL += cooling_sfr/cooling.h INCL += cooling_sfr/cooling.h
...@@ -362,6 +366,7 @@ ifeq (LIGHTCONE_MASSMAPS,$(findstring LIGHTCONE_MASSMAPS,$(CONFIGVARS))) ...@@ -362,6 +366,7 @@ ifeq (LIGHTCONE_MASSMAPS,$(findstring LIGHTCONE_MASSMAPS,$(CONFIGVARS)))
MAPS_LIBS += -lchealpix -lcfitsio #-lcurl MAPS_LIBS += -lchealpix -lcfitsio #-lcurl
endif endif
ifeq (LIGHTCONE_PARTICLES,$(findstring LIGHTCONE_PARTICLES,$(CONFIGVARS))) ifeq (LIGHTCONE_PARTICLES,$(findstring LIGHTCONE_PARTICLES,$(CONFIGVARS)))
MAPS_LIBS += -lchealpix -lcfitsio #-lcurl MAPS_LIBS += -lchealpix -lcfitsio #-lcurl
endif endif
......
...@@ -59,7 +59,6 @@ TIMER_CREATE(CPU_TREEDIRECT, "treedirect", CPU_TREE, 'r', '2') ...@@ -59,7 +59,6 @@ TIMER_CREATE(CPU_TREEDIRECT, "treedirect", CPU_TREE, 'r', '2')
#ifdef PMGRID #ifdef PMGRID
TIMER_CREATE(CPU_PM_GRAVITY, "pm_grav", CPU_ALL, '|', 'n') TIMER_CREATE(CPU_PM_GRAVITY, "pm_grav", CPU_ALL, '|', 'n')
#endif #endif
TIMER_CREATE(CPU_NGBTREEBUILD, "ngbtreebuild", CPU_ALL, 'A', 'a')
TIMER_CREATE(CPU_NGBTREEUPDATEVEL, "ngbtreevelupdate", CPU_ALL, 'B', 'b') TIMER_CREATE(CPU_NGBTREEUPDATEVEL, "ngbtreevelupdate", CPU_ALL, 'B', 'b')
TIMER_CREATE(CPU_NGBTREEUPDATEMAXHSML, "ngbtreehsmlupdate", CPU_ALL, 'h', 'H') TIMER_CREATE(CPU_NGBTREEUPDATEMAXHSML, "ngbtreehsmlupdate", CPU_ALL, 'h', 'H')
TIMER_CREATE(CPU_SPH, "sph", CPU_ALL, 0, 0) TIMER_CREATE(CPU_SPH, "sph", CPU_ALL, 0, 0)
......
...@@ -318,6 +318,10 @@ void sim::begrun2(void) ...@@ -318,6 +318,10 @@ void sim::begrun2(void)
All.FlushLast = Logs.CPUThisRun; All.FlushLast = Logs.CPUThisRun;
#endif #endif
// update All on shared memory handler, just to allow it to access its elements if needed
if(Shmem.Island_NTask != Shmem.World_NTask && Shmem.Island_ThisTask == 0)
MPI_Send(All.get_data_ptr(), All.get_data_size(), MPI_BYTE, Shmem.MyShmRankInGlobal, TAG_ALL_UPDATE, MPI_COMM_WORLD);
#if defined(FORCETEST) && defined(FORCETEST_TESTFORCELAW) #if defined(FORCETEST) && defined(FORCETEST_TESTFORCELAW)
gravity_forcetest_testforcelaw(); gravity_forcetest_testforcelaw();
#endif #endif
......
...@@ -97,6 +97,7 @@ ...@@ -97,6 +97,7 @@
#define TAG_NODE_DATA 84 #define TAG_NODE_DATA 84
#define TAG_RESULTS 85 #define TAG_RESULTS 85
#define TAG_DRIFT_INIT 86 #define TAG_DRIFT_INIT 86
#define TAG_ALL_UPDATE 87
#define TAG_METDATA 500 #define TAG_METDATA 500
#define TAG_FETCH_GRAVTREE 1000 #define TAG_FETCH_GRAVTREE 1000
#define TAG_FETCH_SPH_DENSITY 2000 #define TAG_FETCH_SPH_DENSITY 2000
......
...@@ -200,6 +200,11 @@ void shmem::shared_memory_handler(void) ...@@ -200,6 +200,11 @@ void shmem::shared_memory_handler(void)
Mem.myfree(message); Mem.myfree(message);
Driftfac.init_drift_table(); Driftfac.init_drift_table();
} }
else if(tag == TAG_ALL_UPDATE) // make the shared memory handler update the contents of the All structure
{
memcpy(All.get_data_ptr(), message, All.get_data_size());
Mem.myfree(message);
}
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment