Below is the list of changes that have just been committed into a local
5.0 repository of jonas. When jonas 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
1.1870 05/07/12 16:34:09 joreland@stripped +6 -0
bug#9961 more printouts
ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp
1.16 05/07/12 16:34:05 joreland@stripped +25 -0
bug#9961 more printouts
ndb/src/kernel/blocks/ndbfs/MemoryChannel.hpp
1.5 05/07/12 16:34:05 joreland@stripped +12 -0
bug#9961 more printouts
ndb/src/kernel/blocks/ndbfs/CircularIndex.hpp
1.2 05/07/12 16:34:05 joreland@stripped +2 -2
bug#9961 more printouts
ndb/src/kernel/blocks/ndbfs/AsyncFile.hpp
1.4 05/07/12 16:34:05 joreland@stripped +3 -0
bug#9961 more printouts
ndb/src/kernel/blocks/ndbfs/AsyncFile.cpp
1.18 05/07/12 16:34:05 joreland@stripped +61 -0
bug#9961 more printouts
ndb/src/kernel/blocks/dbdih/DbdihMain.cpp
1.31 05/07/12 16:34:05 joreland@stripped +8 -0
bug#9961 more printouts
# 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: joreland
# Host: eel.(none)
# Root: /home/jonas/src/mysql-5.0
--- 1.30/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp 2005-07-12 16:31:11 +02:00
+++ 1.31/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp 2005-07-12 16:34:05 +02:00
@@ -10334,6 +10334,14 @@
file1Ptr.p->fileStatus, file1Ptr.p->fileType, file1Ptr.p->reqStatus
);
+ signal->theData[0] = 404;
+ signal->theData[1] = file0Ptr.p->fileRef;
+ EXECUTE_DIRECT(NDBFS, GSN_DUMP_STATE_ORD, signal, 2);
+
+ signal->theData[0] = 404;
+ signal->theData[1] = file1Ptr.p->fileRef;
+ EXECUTE_DIRECT(NDBFS, GSN_DUMP_STATE_ORD, signal, 2);
+
ndbout_c("c_COPY_GCIREQ_Counter = %s",
c_COPY_GCIREQ_Counter.getText());
ndbout_c("c_COPY_TABREQ_Counter = %s",
--- 1.17/ndb/src/kernel/blocks/ndbfs/AsyncFile.cpp 2005-05-23 19:36:34 +02:00
+++ 1.18/ndb/src/kernel/blocks/ndbfs/AsyncFile.cpp 2005-07-12 16:34:05 +02:00
@@ -96,6 +96,7 @@
theReportTo(0),
theMemoryChannelPtr(NULL)
{
+ m_current_request= m_last_request= 0;
}
void
@@ -177,6 +178,7 @@
endReq();
return;
}//if
+ m_current_request= request;
switch (request->action) {
case Request:: open:
openReq(request);
@@ -226,6 +228,8 @@
abort();
break;
}//switch
+ m_last_request= request;
+ m_current_request= 0;
theReportTo->writeChannel(request);
}//while
}//AsyncFile::run()
@@ -1031,3 +1035,60 @@
}
#endif
+
+NdbOut&
+operator<<(NdbOut& out, const Request& req)
+{
+ out << "[ Request: file: " << hex << req.file
+ << " userRef: " << hex << req.theUserReference
+ << " userData: " << dec << req.theUserPointer
+ << " theFilePointer: " << req.theFilePointer
+ << " action: ";
+ switch(req.action){
+ case Request::open:
+ out << "open";
+ break;
+ case Request::close:
+ out << "close";
+ break;
+ case Request::closeRemove:
+ out << "closeRemove";
+ break;
+ case Request::read: // Allways leave readv directly after
+ out << "read";
+ break;
+ case Request::readv:
+ out << "readv";
+ break;
+ case Request::write:// Allways leave writev directly after
+ out << "write";
+ break;
+ case Request::writev:
+ out << "writev";
+ break;
+ case Request::writeSync:// Allways leave writevSync directly after
+ out << "writeSync";
+ break;
+ // writeSync because SimblockAsyncFileSystem depends on it
+ case Request::writevSync:
+ out << "writevSync";
+ break;
+ case Request::sync:
+ out << "sync";
+ break;
+ case Request::end:
+ out << "end";
+ break;
+ case Request::append:
+ out << "append";
+ break;
+ case Request::rmrf:
+ out << "rmrf";
+ break;
+ default:
+ out << (Uint32)req.action;
+ break;
+ }
+ out << " ]";
+ return out;
+}
--- 1.3/ndb/src/kernel/blocks/ndbfs/AsyncFile.hpp 2004-08-26 23:43:02 +02:00
+++ 1.4/ndb/src/kernel/blocks/ndbfs/AsyncFile.hpp 2005-07-12 16:34:05 +02:00
@@ -160,6 +160,7 @@
Uint32 theTrace;
};
+NdbOut& operator <<(NdbOut&, const Request&);
inline
void
@@ -173,6 +174,7 @@
class AsyncFile
{
+ friend class Ndbfs;
public:
AsyncFile();
~AsyncFile();
@@ -188,6 +190,7 @@
bool isOpen();
Filename theFileName;
+ Request *m_current_request, *m_last_request;
private:
void openReq(Request *request);
--- 1.1/ndb/src/kernel/blocks/ndbfs/CircularIndex.hpp 2004-04-14 10:24:20 +02:00
+++ 1.2/ndb/src/kernel/blocks/ndbfs/CircularIndex.hpp 2005-07-12 16:34:05 +02:00
@@ -68,7 +68,7 @@
{
public:
inline CircularIndex( int start= 0,int size=256 );
- operator int ();
+ operator int () const;
CircularIndex& operator ++ ();
friend int full( const CircularIndex& write, const CircularIndex& read );
friend int empty( const CircularIndex& write, const CircularIndex& read );
@@ -77,7 +77,7 @@
int theIndex;
};
-inline CircularIndex::operator int ()
+inline CircularIndex::operator int () const
{
return theIndex;
}
--- 1.4/ndb/src/kernel/blocks/ndbfs/MemoryChannel.hpp 2004-07-09 10:00:07 +02:00
+++ 1.5/ndb/src/kernel/blocks/ndbfs/MemoryChannel.hpp 2005-07-12 16:34:05 +02:00
@@ -96,8 +96,20 @@
NdbMutex* theMutexPtr;
NdbCondition* theConditionPtr;
+ template<class U>
+ friend NdbOut& operator<<(NdbOut& out, const MemoryChannel<U> & chn);
};
+template <class T>
+NdbOut& operator<<(NdbOut& out, const MemoryChannel<T> & chn)
+{
+ NdbMutex_Lock(chn.theMutexPtr);
+ out << "[ theSize: " << chn.theSize
+ << " theReadIndex: " << (int)chn.theReadIndex
+ << " theWriteIndex: " << (int)chn.theWriteIndex << " ]";
+ NdbMutex_Unlock(chn.theMutexPtr);
+ return out;
+}
template <class T> MemoryChannel<T>::MemoryChannel( int size):
theSize(size),
--- 1.15/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp 2005-06-09 07:49:45 +02:00
+++ 1.16/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp 2005-07-12 16:34:05 +02:00
@@ -1006,6 +1006,30 @@
}
return;
}
+
+ if(signal->theData[0] == 404)
+ {
+ ndbrequire(signal->getLength() == 2);
+ Uint32 file= signal->theData[1];
+ AsyncFile* openFile = theOpenFiles.find(file);
+ ndbrequire(openFile);
+ ndbout_c("File: %s %p", openFile->theFileName.c_str(), openFile);
+ Request* curr = openFile->m_current_request;
+ Request* last = openFile->m_last_request;
+ if(curr)
+ ndbout << "Current request: " << *curr << endl;
+ if(last)
+ ndbout << "Last request: " << *last << endl;
+
+ ndbout << "theReportTo " << *openFile->theReportTo << endl;
+ ndbout << "theMemoryChannelPtr" << *openFile->theMemoryChannelPtr << endl;
+
+ ndbout << "All files: " << endl;
+ for (unsigned i = 0; i < theFiles.size(); i++){
+ AsyncFile* file = theFiles[i];
+ ndbout_c("%2d (0x%x): %s", i,file, file->isOpen()?"OPEN":"CLOSED");
+ }
+ }
}//Ndbfs::execDUMP_STATE_ORD()
@@ -1016,3 +1040,4 @@
template class Vector<OpenFiles::OpenFileItem>;
template class MemoryChannel<Request>;
template class Pool<Request>;
+template NdbOut& operator<<(NdbOut&, const MemoryChannel<Request>&);
| Thread |
|---|
| • bk commit into 5.0 tree (joreland:1.1870) BUG#9961 | jonas.oreland | 12 Jul |