add analyseThread and msgDiag