fix: logging of OpenMP threads in main (CURA-3330)
Esse commit está contido em:
@@ -32,17 +32,6 @@ namespace cura
|
||||
|
||||
bool FffPolygonGenerator::generateAreas(SliceDataStorage& storage, MeshGroup* meshgroup, TimeKeeper& timeKeeper)
|
||||
{
|
||||
#pragma omp parallel
|
||||
{
|
||||
#pragma omp master
|
||||
{
|
||||
#ifdef _OPENMP
|
||||
log("OpenMP enabled, number of threads used: %u\n", omp_get_num_threads());
|
||||
#else
|
||||
log("OpenMP disabled\n");
|
||||
#endif
|
||||
}
|
||||
}
|
||||
if (!sliceModel(meshgroup, timeKeeper, storage))
|
||||
{
|
||||
return false;
|
||||
|
||||
+15
-1
@@ -20,6 +20,8 @@
|
||||
|
||||
#include "settings/SettingsToGV.h"
|
||||
|
||||
#include <omp.h> // omp_get_num_threads
|
||||
|
||||
namespace cura
|
||||
{
|
||||
|
||||
@@ -328,7 +330,19 @@ int main(int argc, char **argv)
|
||||
print_usage();
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
#pragma omp parallel
|
||||
{
|
||||
#pragma omp master
|
||||
{
|
||||
#ifdef _OPENMP
|
||||
log("OpenMP multithreading enabled, likely number of threads to be used: %u\n", omp_get_num_threads());
|
||||
#else
|
||||
log("OpenMP multithreading disabled\n");
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
if (stringcasecompare(argv[1], "connect") == 0)
|
||||
{
|
||||
connect(argc, argv);
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário