From 277fb1a31fc4b0c9691b3bbab43fd1a970d3e575 Mon Sep 17 00:00:00 2001 From: Jens Verwiebe Date: Mon, 31 Mar 2014 13:51:40 +0200 Subject: Sculpt/dyntopo: Make the omp threads configurable to overcome performance issues - autodetect optimal default, which typically avoids HT threads - can store setting in .blend per scene - this does not touch general omp max threads, due i found other areas where the calculations are fitting for huge corecount - Intel notes, some of the older generation processors with HyperThreading would not provide significant performance boost for FPU intensive applications. On those systems you might want to set OMP_NUM_THREADS = total number of cores (not total number of hardware theads). --- source/blender/makesdna/DNA_scene_types.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h index b9621b4753c..cc16ccd201d 100644 --- a/source/blender/makesdna/DNA_scene_types.h +++ b/source/blender/makesdna/DNA_scene_types.h @@ -1224,6 +1224,10 @@ typedef struct Scene { /* RigidBody simulation world+settings */ struct RigidBodyWorld *rigidbody_world; + + /* Openmp Global Settings */ + int omp_num_threads; + int omp_mode; } Scene; @@ -1769,6 +1773,10 @@ typedef enum SculptFlags { #define USER_UNIT_OPT_SPLIT 1 #define USER_UNIT_ROT_RADIANS 2 +/* OpenMP settings */ +#define SCE_OMP_AUTO 0 +#define SCE_OMP_MANUAL 1 + #ifdef __cplusplus } #endif -- cgit v1.2.3