Projects
Games
togaII-141
togaII-141-multithreading.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File togaII-141-multithreading.patch of Package togaII-141
--- option.cpp.orig 2008-01-30 23:59:58.000000000 +0100 +++ option.cpp 2009-08-21 21:01:09.000000000 +0200 @@ -74,7 +74,7 @@ { "Toga King Safety Margin", true, "1700", "spin", "min 500 max 3000", NULL }, { "Toga Extended History Pruning",true, "false", "check", "", NULL }, { "Toga History Threshold", false, "40", "spin", "min 0 max 100", NULL }, - + { "Number of Threads", true, "1", "spin", "min 1 max 16", NULL }, { NULL, false, NULL, NULL, NULL, NULL, }, }; --- protocol.cpp.orig 2008-10-22 09:50:44.000000000 +0200 +++ protocol.cpp 2009-08-21 21:01:09.000000000 +0200 @@ -112,8 +112,11 @@ // late initialisation Init = true; + + NumberThreads=option_get_int("Number of Threads"); + if(NumberThreads>MaxThreads) NumberThreads=MaxThreads; - book_parameter(); + book_parameter(); //SearchInput->multipv = option_get_int("MultiPV"); --- search.cpp.orig 2008-10-22 09:50:44.000000000 +0200 +++ search.cpp 2009-08-21 21:01:09.000000000 +0200 @@ -70,6 +70,9 @@ static pthread_t threat_handle[MaxThreads]; static my_sem_t thread_runnable[MaxThreads]; #endif + +int NumberThreads = 1; + //bool trans_endgame; //CRITICAL_SECTION CriticalSection; --- search.h.orig 2008-01-15 21:17:28.000000000 +0100 +++ search.h 2009-08-21 21:01:09.000000000 +0200 @@ -17,7 +17,6 @@ const int MultiPVMax = 10; const int MaxThreads = 16; -const int NumberThreads = 2; const int DepthMax = 64; const int HeightMax = 256; @@ -114,6 +113,7 @@ extern search_best_t SearchBest[MaxThreads][MultiPVMax]; extern search_root_t SearchRoot[MaxThreads][1]; extern search_current_t SearchCurrent[MaxThreads][1]; +extern int NumberThreads; // functions
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.