List:Commits« Previous MessageNext Message »
From:John David Duncan Date:March 22 2012 10:23pm
Subject:bzr push into mysql-5.5-cluster-7.2 branch (john.duncan:3857 to 3858)
View as plain text  
 3858 John David Duncan	2012-03-22 [merge]
      local merge

    modified:
      storage/ndb/memcache/include/NdbInstance.h
      storage/ndb/memcache/include/QueryPlan.h
      storage/ndb/memcache/scripts/pmpstack.awk
      storage/ndb/memcache/src/NdbInstance.cc
      storage/ndb/memcache/src/ndb_worker.cc
 3857 John David Duncan	2012-03-22 [merge]
      merge

    modified:
      storage/ndb/memcache/src/schedulers/S_sched.cc
=== modified file 'storage/ndb/memcache/include/NdbInstance.h'
--- a/storage/ndb/memcache/include/NdbInstance.h	2012-03-07 01:22:53 +0000
+++ b/storage/ndb/memcache/include/NdbInstance.h	2012-03-22 22:18:19 +0000
@@ -42,6 +42,7 @@ public:
   /* Public Methods */
   NdbInstance(Ndb_cluster_connection *, int);
   ~NdbInstance();
+  void non_blocking_close(NdbTransaction *);
   void link_workitem(workitem *);
   void unlink_workitem(workitem *);
 

=== modified file 'storage/ndb/memcache/include/QueryPlan.h'
--- a/storage/ndb/memcache/include/QueryPlan.h	2011-12-11 07:31:26 +0000
+++ b/storage/ndb/memcache/include/QueryPlan.h	2012-03-22 22:18:19 +0000
@@ -52,7 +52,7 @@ class QueryPlan {
   ~QueryPlan();
   bool canHaveExternalValue() const;
   bool shouldExternalizeValue(size_t length) const;
-  bool canUseSimpleRead() const;
+  bool canUseCommittedRead() const;
   Uint64 getAutoIncrement() const;
   void debug_dump() const;
   bool hasDataOnDisk() const;
@@ -103,7 +103,7 @@ inline bool QueryPlan::hasDataOnDisk() c
   return has_disk_storage;
 }
 
-inline bool QueryPlan::canUseSimpleRead() const {
+inline bool QueryPlan::canUseCommittedRead() const {
   return(pk_access && (! extern_store) && (! spec->exp_column));
 }
 

=== modified file 'storage/ndb/memcache/scripts/pmpstack.awk'
--- a/storage/ndb/memcache/scripts/pmpstack.awk	2011-11-07 21:54:07 +0000
+++ b/storage/ndb/memcache/scripts/pmpstack.awk	2012-03-22 22:18:19 +0000
@@ -41,23 +41,35 @@ function label(name)  {
 ### What is the thread doing? 
 ### Patterns higher up in this file take precedence over lower ones
 
-$2 ~ /^epoll_wait,TransporterRegistry::po/ { label("epoll_wait_transporter_recv"); next }
-                                             
-$2 ~ /^epoll_wait/                         { label("epoll_wait"); next }
+/epoll_wait,TransporterRegistry::po/       { label("epoll_wait_transporter_recv"); next }
+
+/writev,TCP_Transporter::doSend/           { label("sending_to_ndb"); next }
+
+/recv,TCP_Transporter/                     { label("tcp_recv_from_ndb"); next }
 
-$2 ~ /^writev,TCP_Transporter::doSend/     { label("sending_to_ndb"); next }
+/Ndb::closeTransaction/                    { label("ndb_transaction_close"); next } 
 
-$2 ~ /^recv,TCP_Transporter/               { label("tcp_recv_from_ndb"); next }
+/sendmsg,conn_mwrite/                      { label("writing_to_client"); next }
 
-$2 ~ /^sendmsg,conn_mwrite/                { label("sending_to_client"); next }
+/recv,conn_read,event_handler/             { label("reading_from_client"); next }
+
+/poll_dispatch/                            { label("poll_dispatch"); next } 
 
 /pthread_mutex_unlock/                     { label("releasing_locks"); next }
 
+/_lock,pthread_cond_/                      { label("getting_lock_for_condition_var"); next }
+
 /pthread_mutex_lock,Ndb::sendPrepared/     { label("lock_Ndb_impl"); next }
 
 /_mutex_lock/ && /TransporterFacade/       { label("lock_transporter_facade_mutex"); next }
 
 /pthread_cond_timedwait/ && /ollNdb/       { label("wait_poll_ndb"); next }
+
+/::schedule/ && /pthread_cond_signal/      { label("Scheduler_signaling_cond_var") ; next }
+
+/pthread_rwlock_rdlock/                    { label("acquiring_rwlock") ; next } 
+
+/pthread_cond_[a-z]*wait/                  { label("condition_variable_wait"); next }
                                         
 /workqueue_consumer_wait/                  { label("workqueue_idle_wait"); next }
 
@@ -67,6 +79,12 @@ $2 ~ /^sendmsg,conn_mwrite/             
 
 /Ndb::computeHash/                         { label("ndb_compute_hash"); next }
 
+/workitem__initialize/                     { label("workitem_initialize"); next } 
+
+/worker_prepare_operation/                 { label("worker_prepare_operation"); next } 
+                                             
+/^epoll_wait/                              { label("epoll_wait"); next }
+
 /sleep/                                    { label("sleep"); next }
 
 
@@ -74,26 +92,26 @@ $2 ~ /^sendmsg,conn_mwrite/             
 
 END { 
       for(i in event) if (i != "total")
-       printf("%s\t%.2f%%\t%s\n", 
+       printf("%s\t%.2f%% \t%s\n", 
               "Event", (event[i] / event["total"]) * 100, i)
       printf("\n");
 
       for(i in commit) if(i != "total")
-       printf("%s\t%.2f%%\t%s\n", 
+       printf("%s\t%.2f%% \t%s\n", 
               "Commit", (commit[i] / commit["total"]) * 100, i)
       if(commit["total"]) printf("\n");
 
       for(i in send) if(i != "total")
-       printf("%s\t%.2f%%\t%s\n", 
+       printf("%s\t%.2f%% \t%s\n", 
               "Send", (send[i] / send["total"]) * 100, i)
       if(send["total"]) printf("\n");
 
       for(i in poll) if(i != "total")
-       printf("%s\t%.2f%%\t%s\n", 
+       printf("%s\t%.2f%% \t%s\n", 
               "Poll", (poll[i] / poll["total"]) * 100, i)
       if(poll["total"]) printf("\n");
 
       for(i in x) if(i != "total")
-       printf("%s\t%.2f%%\t%s\n", 
+       printf("%s\t%.2f%% \t%s\n", 
               "Unidentified", (x[i] / x["total"]) * 100, i)
     }

=== modified file 'storage/ndb/memcache/src/NdbInstance.cc'
--- a/storage/ndb/memcache/src/NdbInstance.cc	2011-09-30 17:04:30 +0000
+++ b/storage/ndb/memcache/src/NdbInstance.cc	2012-03-22 22:18:19 +0000
@@ -48,3 +48,13 @@ NdbInstance::~NdbInstance() {
 }
 
 
+void NdbInstance::non_blocking_close(NdbTransaction *tx) {
+  Uint64 nwaits_pre, nwaits_post;
+  nwaits_pre = db->getClientStat(Ndb::WaitExecCompleteCount);
+
+  tx->close();
+
+  nwaits_post = db->getClientStat(Ndb::WaitExecCompleteCount);  
+  assert(nwaits_pre == nwaits_post);
+}
+

=== modified file 'storage/ndb/memcache/src/ndb_worker.cc'
--- a/storage/ndb/memcache/src/ndb_worker.cc	2012-03-15 03:21:12 +0000
+++ b/storage/ndb/memcache/src/ndb_worker.cc	2012-03-22 22:18:19 +0000
@@ -460,8 +460,8 @@ op_status_t WorkerStep1::do_read() {
   
   NdbOperation::LockMode lockmode;
   NdbTransaction::ExecType commitflag;
-  if(plan->canUseSimpleRead()) {
-    lockmode = NdbOperation::LM_SimpleRead;
+  if(plan->canUseCommittedRead()) {
+    lockmode = NdbOperation::LM_CommittedRead;
     commitflag = NdbTransaction::Commit;
   }
   else {

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.5-cluster-7.2 branch (john.duncan:3857 to 3858) John David Duncan23 Mar