include examples/python/exec-async/exec-async.tesh
include examples/python/exec-basic/exec-basic.py
include examples/python/exec-basic/exec-basic.tesh
-include examples/python/exec-basic/exec-ptask.py
-include examples/python/exec-basic/exec-ptask.tesh
include examples/python/exec-cpu-nonlinear/exec-cpu-nonlinear.py
include examples/python/exec-cpu-nonlinear/exec-cpu-nonlinear.tesh
include examples/python/exec-dvfs/exec-dvfs.py
include examples/python/exec-dvfs/exec-dvfs.tesh
+include examples/python/exec-ptask/exec-ptask.py
+include examples/python/exec-ptask/exec-ptask.tesh
include examples/python/exec-remote/exec-remote.py
include examples/python/exec-remote/exec-remote.tesh
include examples/python/io-degradation/io-degradation.py
include examples/smpi/trace_simple/trace_simple.c
include examples/smpi/trace_simple/trace_simple.tesh
include examples/sthread/pthread-mutex-simple.c
+include examples/sthread/pthread-mutex-simple.tesh
include examples/sthread/sthread-mutex-simple.c
include src/include/catch_simgrid.hpp
include teshsuite/java/semaphoregc/SemaphoreGC.java
/* create each leaf in the Fat-Tree, return a pair composed of: <object (host, zone), gateway> */
static std::pair<simgrid::kernel::routing::NetPoint*, simgrid::kernel::routing::NetPoint*>
- create_hostzone(const sg4::NetZone* zone, const std::vector<unsigned int>& /*coord*/, int id)
+ create_hostzone(const sg4::NetZone* zone, const std::vector<unsigned long>& /*coord*/, unsigned long id)
{
/* creating zone */
std::string hostname = "host" + std::to_string(id);
endforeach()
endif()
-if (SIMGRID_HAVE_MC)
- # Hijack some regular tests to run them on top of the MC
- foreach (example synchro-barrier synchro-mutex synchro-semaphore)
- set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/${example}/s4u-mc-${example}.tesh)
+# Hijack some regular tests to run them on top of the MC
+foreach (example synchro-barrier synchro-mutex synchro-semaphore)
+ set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/${example}/s4u-mc-${example}.tesh)
+ if (SIMGRID_HAVE_MC)
ADD_TESH(s4u-mc-${example}
--setenv bindir=${CMAKE_CURRENT_BINARY_DIR}/${example}
--setenv libdir=${CMAKE_BINARY_DIR}/lib
${CMAKE_HOME_DIRECTORY}/examples/cpp/${example}/s4u-mc-${example}.tesh)
add_dependencies(tests-mc s4u-${example})
- endforeach()
+ endif()
+endforeach()
+if (SIMGRID_HAVE_MC)
# Dependency on the regular tests
foreach(example mc-centralized-mutex)
add_dependencies(tests-mc s4u-${example})
NativeLib.nativeInit("simgrid");
NativeLib.nativeInit("simgrid-java");
isNativeInited = true;
+
+ /* Don't leak the files on disk */
+ if (tempDir != null) {
+ FileCleaner fclean = new FileCleaner(tempDir.toFile());
+ fclean.run();
+ }
}
/** Helper function trying to load one requested library */
}
tempDir = Files.createTempDirectory(tempPrefix);
- // don't leak the files on disk, but remove it on JVM shutdown
- Runtime.getRuntime().addShutdownHook(new Thread(new FileCleaner(tempDir.toFile())));
}
/* For each possible filename of the given library on all possible OSes, try it */
return raw_pthread_create(thread, attr, start_routine, arg);
sthread_inside_simgrid = 1;
- int res = sthread_create(thread, attr, start_routine, arg);
+ int res = sthread_create((sthread_t*)thread, attr, start_routine, arg);
sthread_inside_simgrid = 0;
return res;
}
return raw_pthread_join(thread, retval);
sthread_inside_simgrid = 1;
- int res = sthread_join(thread, retval);
+ int res = sthread_join((sthread_t)thread, retval);
sthread_inside_simgrid = 0;
return res;
}
intercepter_init();
if (sthread_inside_simgrid)
- return raw_gettimeofday(tv, (void*)tz);
+ return raw_gettimeofday(tv, tz);
sthread_inside_simgrid = 1;
int res = sthread_gettimeofday(tv);
return raw_sem_post(sem);
}
-int pthread_join(pthread_t thread, void **retval) {
- sg_actor_join(thread, -1);
- return 0;
-}
-
int pthread_cond_init(pthread_cond_t *cond, pthread_condattr_t *cond_attr) {
*cond = sg_cond_init();
return 0;
return raw_sem_post(sem);
}
-int pthread_join(pthread_t thread, void **retval) {
- sg_actor_join(thread, -1);
- return 0;
-}
-
int pthread_cond_init(pthread_cond_t *cond, pthread_condattr_t *cond_attr) {
*cond = sg_cond_init();
return 0;
auto* cpu =
englobing_zone_->get_cpu_vm_model()->create_cpu(vm, speeds)->set_core_count(vm->get_vm_impl()->get_core_amount());
- if (get_iface()->get_pstate() != 0)
- cpu->set_pstate(get_iface()->get_pstate());
-
cpu->seal();
+ if (get_iface()->get_pstate() != 0) {
+ cpu->set_pstate(get_iface()->get_pstate());
+ }
+
/* Currently, a VM uses the network resource of its physical host */
vm->set_netpoint(get_iface()->get_netpoint());
p Test allreduce
! output sort
-$ ${bindir:=.}/../../../smpi_script/bin/smpirun -map -hostfile ../hostfile_coll -platform ${platfdir:=.}/small_platform.xml -np 16 --log=xbt_cfg.thres:critical ${bindir:=.}/coll-allreduce --log=smpi_config.thres:warning --log=smpi_coll.thres:error --cfg=smpi/allreduce:automatic --cfg=smpi/async-small-thresh:65536 --cfg=smpi/send-is-detached-thresh:128000 --cfg=smpi/simulate-computation:no "--log=root.fmt:[%10.6r]%e(%i:%a@%h)%e%m%n" --log=smpi_mpi.thres:error --log=smpi_pmpi.thres:error
+$ ${bindir:=.}/../../../smpi_script/bin/smpirun -map -hostfile ../hostfile_coll -platform ${platfdir:=.}/small_platform.xml -np 16 --log=xbt_cfg.thres:critical ${bindir:=.}/coll-allreduce --log=smpi_config.thres:warning --log=smpi_coll.thres:error --cfg=smpi/allreduce:automatic --cfg=smpi/async-small-thresh:65536 --cfg=smpi/send-is-detached-thresh:128000 --cfg=smpi/simulate-computation:no "--log=root.fmt:[%10.6r]%e(%i:%a@%h)%e%m%n" --log=smpi_mpi.thres:error --log=smpi_pmpi.thres:error --log=root.app:stdout
> [ 0.000000] (0:maestro@) [rank 0] -> Tremblay
> [ 0.000000] (0:maestro@) [rank 1] -> Tremblay
> [ 0.000000] (0:maestro@) [rank 2] -> Tremblay