Below is the list of changes that have just been committed into a local
5.1 repository of mikron. When mikron does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-05-15 19:55:59+02:00, mikron@stripped +4 -0
Added comments for constants
storage/ndb/include/portlib/NdbThread.h@stripped, 2007-05-15 19:55:56+02:00, mikron@stripped +1 -0
Added constant to avoid ahving to include Configuration.hpp in
various low-level header files
storage/ndb/src/common/portlib/NdbThread.c@stripped, 2007-05-15 19:55:56+02:00, mikron@stripped +16 -2
Added comments for constants
storage/ndb/src/common/transporter/TransporterRegistry.cpp@stripped, 2007-05-15 19:55:56+02:00, mikron@stripped +1 -1
Added comments for constants
storage/ndb/src/common/util/SocketServer.cpp@stripped, 2007-05-15 19:55:56+02:00, mikron@stripped +1 -1
Added comments for constants
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: mikron
# Host: mikael-ronstr-ms-dator.local
# Root: /Users/mikron/mysql_clones/sched_rt
--- 1.8/storage/ndb/include/portlib/NdbThread.h 2007-05-08 07:19:10 +02:00
+++ 1.9/storage/ndb/include/portlib/NdbThread.h 2007-05-15 19:55:56 +02:00
@@ -22,6 +22,7 @@
extern "C" {
#endif
+#define THREAD_CONTAINER_SIZE 128
typedef enum NDB_THREAD_PRIO_ENUM {
NDB_THREAD_PRIO_HIGHEST,
NDB_THREAD_PRIO_HIGH,
--- 1.34/storage/ndb/src/common/portlib/NdbThread.c 2007-05-08 07:19:10 +02:00
+++ 1.35/storage/ndb/src/common/portlib/NdbThread.c 2007-05-15 19:55:56 +02:00
@@ -51,8 +51,8 @@
NDB_THREAD_FUNC *start_func;
NDB_THREAD_FUNC *end_func;
bool same_start_end_object;
- char start_object[128];
- char end_object[128];
+ char start_object[THREAD_CONTAINER_SIZE];
+ char end_object[THREAD_CONTAINER_SIZE];
};
#ifdef NDB_SHM_TRANSPORTER
@@ -295,6 +295,10 @@
#ifdef HAVE_SCHED_GET_PRIORITY_MAX
max_prio = sched_get_priority_max(policy);
#else
+ /*
+ Should normally not be used, on Linux RT-prio is between 1 and 100
+ so choose 90 mostly from Linux point of view
+ */
max_prio = 90;
#endif
return max_prio;
@@ -307,6 +311,7 @@
#ifdef HAVE_SCHED_GET_PRIORITY_MIN
min_prio = sched_get_priority_min(policy);
#else
+ /* 1 seems like a natural minimum priority level */
min_prio = 1;
#endif
return min_prio;
@@ -320,6 +325,15 @@
return 0;
max_prio = get_max_prio(policy);
min_prio = get_min_prio(policy);
+ /*
+ We need to distinguish between high and low priority threads. High
+ priority threads are the threads that don't execute the main thread.
+ It's important that these threads are at a higher priority than the
+ main thread since the main thread can execute for a very long time.
+ There are no reasons to put these priorities higher than the lowest
+ priority and the distance between them being two to enable for future
+ extensions where a new priority level is required.
+ */
if (high_prio)
prio = min_prio + 3;
else
--- 1.72/storage/ndb/src/common/transporter/TransporterRegistry.cpp 2007-05-08 07:19:10 +02:00
+++ 1.73/storage/ndb/src/common/transporter/TransporterRegistry.cpp 2007-05-15 19:55:56 +02:00
@@ -1164,7 +1164,7 @@
bool
TransporterRegistry::start_clients()
{
- char thread_object[128];
+ char thread_object[THREAD_CONTAINER_SIZE];
uint len;
m_run_start_clients_thread= true;
--- 1.25/storage/ndb/src/common/util/SocketServer.cpp 2007-05-08 07:19:10 +02:00
+++ 1.26/storage/ndb/src/common/util/SocketServer.cpp 2007-05-15 19:55:56 +02:00
@@ -214,7 +214,7 @@
void
SocketServer::startServer()
{
- char thread_object[128];
+ char thread_object[THREAD_CONTAINER_SIZE];
uint len;
m_threadLock.lock();
| Thread |
|---|
| • bk commit into 5.1 tree (mikron:1.2518) | mikael | 17 May |