Skip to content

Commit 3dbbb56

Browse files
committed
engine: initialize Omp
1 parent 1740152 commit 3dbbb56

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

src/engine/framework/System.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3434
#include "ConsoleHistory.h"
3535
#include "CommandSystem.h"
3636
#include "LogSystem.h"
37+
#include "Omp.h"
3738
#include "System.h"
3839
#include "CrashDump.h"
3940
#include "CvarSystem.h"
@@ -829,6 +830,8 @@ static void SetCvarsWithInitFlag(cmdlineArgs_t& cmdlineArgs)
829830
// Initialize the engine
830831
static void Init(int argc, char** argv)
831832
{
833+
Omp::Init();
834+
832835
cmdlineArgs_t cmdlineArgs;
833836

834837
#ifdef _WIN32

src/engine/qcommon/common.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ Maryland 20850 USA.
4747
#include "framework/CommandSystem.h"
4848
#include "framework/CvarSystem.h"
4949
#include "framework/LogSystem.h"
50+
#include "framework/Omp.h"
5051
#include "framework/System.h"
5152
#include "sys/sys_events.h"
5253
#include <common/FileSystem.h>
@@ -783,6 +784,8 @@ static Cvar::Cvar<bool> showTraceStats("common.showTraceStats", "are physics tra
783784

784785
void Com_Frame()
785786
{
787+
Omp::SetupThreads();
788+
786789
int msec, minMsec;
787790
static int lastTime = 0;
788791
//int key;

0 commit comments

Comments
 (0)