Lines Matching full:log
251 static void qpTestLog_flushFile (qpTestLog* log) in qpTestLog_flushFile() argument
253 DE_ASSERT(log && log->outputFile); in qpTestLog_flushFile()
254 fflush(log->outputFile); in qpTestLog_flushFile()
257 FlushFileBuffers((HANDLE)_get_osfhandle(_fileno(log->outputFile))); in qpTestLog_flushFile()
292 static deBool beginSession (qpTestLog* log) in beginSession() argument
294 DE_ASSERT(log && !log->isSessionOpen); in beginSession()
297 fprintf(log->outputFile, "#sessionInfo releaseName %s\n", qpGetReleaseName()); in beginSession()
298 fprintf(log->outputFile, "#sessionInfo releaseId 0x%08x\n", qpGetReleaseId()); in beginSession()
299 fprintf(log->outputFile, "#sessionInfo targetName \"%s\"\n", qpGetTargetName()); in beginSession()
302 fprintf(log->outputFile, "#beginSession\n"); in beginSession()
303 qpTestLog_flushFile(log); in beginSession()
305 log->isSessionOpen = DE_TRUE; in beginSession()
310 static deBool endSession (qpTestLog* log) in endSession() argument
312 DE_ASSERT(log && log->isSessionOpen); in endSession()
315 qpXmlWriter_flush(log->writer); in endSession()
318 fprintf(log->outputFile, "\n#endSession\n"); in endSession()
319 qpTestLog_flushFile(log); in endSession()
321 log->isSessionOpen = DE_FALSE; in endSession()
333 qpTestLog* log = (qpTestLog*)deCalloc(sizeof(qpTestLog)); in qpTestLog_createFileLog() local
334 if (!log) in qpTestLog_createFileLog()
340 ContainerStack_reset(&log->containerStack); in qpTestLog_createFileLog()
343 qpPrintf("Writing test log into %s\n", fileName); in qpTestLog_createFileLog()
346 log->outputFile = fopen(fileName, "wb"); in qpTestLog_createFileLog()
347 if (!log->outputFile) in qpTestLog_createFileLog()
349 qpPrintf("ERROR: Unable to open test log output file '%s'.\n", fileName); in qpTestLog_createFileLog()
350 qpTestLog_destroy(log); in qpTestLog_createFileLog()
354 log->flags = flags; in qpTestLog_createFileLog()
355 log->writer = qpXmlWriter_createFileWriter(log->outputFile, 0, !(flags & QP_TEST_LOG_NO_FLUSH)); in qpTestLog_createFileLog()
356 log->lock = deMutex_create(DE_NULL); in qpTestLog_createFileLog()
357 log->isSessionOpen = DE_FALSE; in qpTestLog_createFileLog()
358 log->isCaseOpen = DE_FALSE; in qpTestLog_createFileLog()
360 if (!log->writer) in qpTestLog_createFileLog()
363 qpTestLog_destroy(log); in qpTestLog_createFileLog()
367 if (!log->lock) in qpTestLog_createFileLog()
370 qpTestLog_destroy(log); in qpTestLog_createFileLog()
374 beginSession(log); in qpTestLog_createFileLog()
376 return log; in qpTestLog_createFileLog()
383 void qpTestLog_destroy (qpTestLog* log) in qpTestLog_destroy() argument
385 DE_ASSERT(log); in qpTestLog_destroy()
387 if (log->isSessionOpen) in qpTestLog_destroy()
388 endSession(log); in qpTestLog_destroy()
390 if (log->writer) in qpTestLog_destroy()
391 qpXmlWriter_destroy(log->writer); in qpTestLog_destroy()
393 if (log->outputFile) in qpTestLog_destroy()
394 fclose(log->outputFile); in qpTestLog_destroy()
396 if (log->lock) in qpTestLog_destroy()
397 deMutex_destroy(log->lock); in qpTestLog_destroy()
399 deFree(log); in qpTestLog_destroy()
403 * \brief Log start of test case
404 * \param log qpTestLog instance
409 deBool qpTestLog_startCase (qpTestLog* log, const char* testCasePath, qpTestCaseType testCaseType) in qpTestLog_startCase() argument
415 DE_ASSERT(log && testCasePath && (testCasePath[0] != 0)); in qpTestLog_startCase()
416 deMutex_lock(log->lock); in qpTestLog_startCase()
418 DE_ASSERT(!log->isCaseOpen); in qpTestLog_startCase()
419 DE_ASSERT(ContainerStack_isEmpty(&log->containerStack)); in qpTestLog_startCase()
422 qpXmlWriter_flush(log->writer); in qpTestLog_startCase()
423 fprintf(log->outputFile, "\n#beginTestCaseResult %s\n", testCasePath); in qpTestLog_startCase()
424 if (!(log->flags & QP_TEST_LOG_NO_FLUSH)) in qpTestLog_startCase()
425 qpTestLog_flushFile(log); in qpTestLog_startCase()
427 log->isCaseOpen = DE_TRUE; in qpTestLog_startCase()
434 if (!qpXmlWriter_startDocument(log->writer) || in qpTestLog_startCase()
435 !qpXmlWriter_startElement(log->writer, "TestCaseResult", numResultAttribs, resultAttribs)) in qpTestLog_startCase()
438 deMutex_unlock(log->lock); in qpTestLog_startCase()
442 deMutex_unlock(log->lock); in qpTestLog_startCase()
447 * \brief Log end of test case
448 * \param log qpTestLog instance
453 deBool qpTestLog_endCase (qpTestLog* log, qpTestResult result, const char* resultDetails) in qpTestLog_endCase() argument
458 deMutex_lock(log->lock); in qpTestLog_endCase()
460 DE_ASSERT(log->isCaseOpen); in qpTestLog_endCase()
461 DE_ASSERT(ContainerStack_isEmpty(&log->containerStack)); in qpTestLog_endCase()
466 if (!qpXmlWriter_startElement(log->writer, "Result", 1, &statusAttrib) || in qpTestLog_endCase()
467 (resultDetails && !qpXmlWriter_writeString(log->writer, resultDetails)) || in qpTestLog_endCase()
468 !qpXmlWriter_endElement(log->writer, "Result") || in qpTestLog_endCase()
469 !qpXmlWriter_endElement(log->writer, "TestCaseResult") || in qpTestLog_endCase()
470 !qpXmlWriter_endDocument(log->writer)) /* Close any XML elements still open */ in qpTestLog_endCase()
473 deMutex_unlock(log->lock); in qpTestLog_endCase()
478 qpXmlWriter_flush(log->writer); in qpTestLog_endCase()
479 fprintf(log->outputFile, "\n#endTestCaseResult\n"); in qpTestLog_endCase()
480 if (!(log->flags & QP_TEST_LOG_NO_FLUSH)) in qpTestLog_endCase()
481 qpTestLog_flushFile(log); in qpTestLog_endCase()
483 log->isCaseOpen = DE_FALSE; in qpTestLog_endCase()
485 deMutex_unlock(log->lock); in qpTestLog_endCase()
489 deBool qpTestLog_startTestsCasesTime (qpTestLog* log) in qpTestLog_startTestsCasesTime() argument
491 DE_ASSERT(log); in qpTestLog_startTestsCasesTime()
492 deMutex_lock(log->lock); in qpTestLog_startTestsCasesTime()
495 qpXmlWriter_flush(log->writer); in qpTestLog_startTestsCasesTime()
496 fprintf(log->outputFile, "\n#beginTestsCasesTime\n"); in qpTestLog_startTestsCasesTime()
498 log->isCaseOpen = DE_TRUE; in qpTestLog_startTestsCasesTime()
500 if (!qpXmlWriter_startDocument(log->writer) || in qpTestLog_startTestsCasesTime()
501 !qpXmlWriter_startElement(log->writer, "TestsCasesTime", 0, (const qpXmlAttribute*)DE_NULL)) in qpTestLog_startTestsCasesTime()
504 deMutex_unlock(log->lock); in qpTestLog_startTestsCasesTime()
508 deMutex_unlock(log->lock); in qpTestLog_startTestsCasesTime()
512 deBool qpTestLog_endTestsCasesTime (qpTestLog* log) in qpTestLog_endTestsCasesTime() argument
514 DE_ASSERT(log); in qpTestLog_endTestsCasesTime()
515 deMutex_lock(log->lock); in qpTestLog_endTestsCasesTime()
517 DE_ASSERT(log->isCaseOpen); in qpTestLog_endTestsCasesTime()
519 if (!qpXmlWriter_endElement(log->writer, "TestsCasesTime") || in qpTestLog_endTestsCasesTime()
520 !qpXmlWriter_endDocument(log->writer)) in qpTestLog_endTestsCasesTime()
523 deMutex_unlock(log->lock); in qpTestLog_endTestsCasesTime()
527 qpXmlWriter_flush(log->writer); in qpTestLog_endTestsCasesTime()
529 fprintf(log->outputFile, "\n#endTestsCasesTime\n"); in qpTestLog_endTestsCasesTime()
531 log->isCaseOpen = DE_FALSE; in qpTestLog_endTestsCasesTime()
533 deMutex_unlock(log->lock); in qpTestLog_endTestsCasesTime()
540 * \param log qpTestLog instance
544 deBool qpTestLog_terminateCase (qpTestLog* log, qpTestResult result) in qpTestLog_terminateCase() argument
548 DE_ASSERT(log); in qpTestLog_terminateCase()
551 deMutex_lock(log->lock); in qpTestLog_terminateCase()
553 if (!log->isCaseOpen) in qpTestLog_terminateCase()
555 deMutex_unlock(log->lock); in qpTestLog_terminateCase()
560 qpXmlWriter_flush(log->writer); in qpTestLog_terminateCase()
561 fprintf(log->outputFile, "\n#terminateTestCaseResult %s\n", resultStr); in qpTestLog_terminateCase()
562 qpTestLog_flushFile(log); in qpTestLog_terminateCase()
564 log->isCaseOpen = DE_FALSE; in qpTestLog_terminateCase()
567 ContainerStack_reset(&log->containerStack); in qpTestLog_terminateCase()
570 deMutex_unlock(log->lock); in qpTestLog_terminateCase()
574 static deBool qpTestLog_writeKeyValuePair (qpTestLog* log, const char* elementName, const char* nam… in qpTestLog_writeKeyValuePair() argument
580 DE_ASSERT(log && elementName && text); in qpTestLog_writeKeyValuePair()
581 deMutex_lock(log->lock); in qpTestLog_writeKeyValuePair()
589 if (!qpXmlWriter_startElement(log->writer, elementName, numAttribs, attribs) || in qpTestLog_writeKeyValuePair()
590 !qpXmlWriter_writeString(log->writer, text) || in qpTestLog_writeKeyValuePair()
591 !qpXmlWriter_endElement(log->writer, elementName)) in qpTestLog_writeKeyValuePair()
594 deMutex_unlock(log->lock); in qpTestLog_writeKeyValuePair()
598 deMutex_unlock(log->lock); in qpTestLog_writeKeyValuePair()
603 * \brief Write key-value-pair into log
604 * \param log qpTestLog instance
611 deBool qpTestLog_writeText (qpTestLog* log, const char* name, const char* description, qpKeyValueTa… in qpTestLog_writeText() argument
614 return qpTestLog_writeKeyValuePair(log, "Text", name, description, DE_NULL, tag, text); in qpTestLog_writeText()
618 * \brief Write key-value-pair into log
619 * \param log qpTestLog instance
626 deBool qpTestLog_writeInteger (qpTestLog* log, const char* name, const char* description, const cha… in qpTestLog_writeInteger() argument
632 return qpTestLog_writeKeyValuePair(log, "Number", name, description, unit, tag, tmpString); in qpTestLog_writeInteger()
636 * \brief Write key-value-pair into log
637 * \param log qpTestLog instance
644 deBool qpTestLog_writeFloat (qpTestLog* log, const char* name, const char* description, const char*… in qpTestLog_writeFloat() argument
650 return qpTestLog_writeKeyValuePair(log, "Number", name, description, unit, tag, tmpString); in qpTestLog_writeFloat()
788 * \param log qpTestLog instance
793 deBool qpTestLog_startImageSet (qpTestLog* log, const char* name, const char* description) in qpTestLog_startImageSet() argument
798 DE_ASSERT(log && name); in qpTestLog_startImageSet()
799 deMutex_lock(log->lock); in qpTestLog_startImageSet()
806 if (!qpXmlWriter_startElement(log->writer, "ImageSet", numAttribs, attribs)) in qpTestLog_startImageSet()
809 deMutex_unlock(log->lock); in qpTestLog_startImageSet()
813 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_IMAGESET)); in qpTestLog_startImageSet()
815 deMutex_unlock(log->lock); in qpTestLog_startImageSet()
821 * \param log qpTestLog instance
824 deBool qpTestLog_endImageSet (qpTestLog* log) in qpTestLog_endImageSet() argument
826 DE_ASSERT(log); in qpTestLog_endImageSet()
827 deMutex_lock(log->lock); in qpTestLog_endImageSet()
830 if (!qpXmlWriter_endElement(log->writer, "ImageSet")) in qpTestLog_endImageSet()
833 deMutex_unlock(log->lock); in qpTestLog_endImageSet()
837 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_IMAGESET); in qpTestLog_endImageSet()
839 deMutex_unlock(log->lock); in qpTestLog_endImageSet()
844 * \brief Write base64 encoded raw image data into log
845 * \param log qpTestLog instance
857 qpTestLog* log, in qpTestLog_writeImage() argument
875 DE_ASSERT(log && name); in qpTestLog_writeImage()
880 if (log->flags & QP_TEST_LOG_EXCLUDE_IMAGES) in qpTestLog_writeImage()
967 /* \note Log lock is acquired after compression! */ in qpTestLog_writeImage()
968 deMutex_lock(log->lock); in qpTestLog_writeImage()
971 if (!qpXmlWriter_startElement(log->writer, "Image", numAttribs, attribs) || in qpTestLog_writeImage()
972 !qpXmlWriter_writeBase64(log->writer, (const deUint8*)writeDataPtr, writeDataBytes) || in qpTestLog_writeImage()
973 !qpXmlWriter_endElement(log->writer, "Image")) in qpTestLog_writeImage()
976 deMutex_unlock(log->lock); in qpTestLog_writeImage()
981 deMutex_unlock(log->lock); in qpTestLog_writeImage()
990 * \brief Write a OpenGL ES shader program into the log.
992 * \param linkInfoLog Implementation provided linkage log
994 deBool qpTestLog_startShaderProgram (qpTestLog* log, deBool linkOk, const char* linkInfoLog) in qpTestLog_startShaderProgram() argument
999 DE_ASSERT(log); in qpTestLog_startShaderProgram()
1000 deMutex_lock(log->lock); in qpTestLog_startShaderProgram()
1004 if (!qpXmlWriter_startElement(log->writer, "ShaderProgram", numProgramAttribs, programAttribs) || in qpTestLog_startShaderProgram()
1005 !qpXmlWriter_writeStringElement(log->writer, "InfoLog", linkInfoLog)) in qpTestLog_startShaderProgram()
1008 deMutex_unlock(log->lock); in qpTestLog_startShaderProgram()
1012 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_SHADERPROGRAM)); in qpTestLog_startShaderProgram()
1014 deMutex_unlock(log->lock); in qpTestLog_startShaderProgram()
1020 * \param log qpTestLog instance
1023 deBool qpTestLog_endShaderProgram (qpTestLog* log) in qpTestLog_endShaderProgram() argument
1025 DE_ASSERT(log); in qpTestLog_endShaderProgram()
1026 deMutex_lock(log->lock); in qpTestLog_endShaderProgram()
1029 if (!qpXmlWriter_endElement(log->writer, "ShaderProgram")) in qpTestLog_endShaderProgram()
1032 deMutex_unlock(log->lock); in qpTestLog_endShaderProgram()
1036 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_SHADERPROGRAM); in qpTestLog_endShaderProgram()
1038 deMutex_unlock(log->lock); in qpTestLog_endShaderProgram()
1043 * \brief Write a OpenGL ES shader into the log.
1047 * \param infoLog Implementation provided shader compilation log
1049 deBool qpTestLog_writeShader (qpTestLog* log, qpShaderType type, const char* source, deBool compile… in qpTestLog_writeShader() argument
1052 …const char* sourceStr = ((log->flags & QP_TEST_LOG_EXCLUDE_SHADER_SOURCES) == 0 || !compileOk) … in qpTestLog_writeShader()
1056 deMutex_lock(log->lock); in qpTestLog_writeShader()
1059 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SHADERPROGRAM); in qpTestLog_writeShader()
1063 if (!qpXmlWriter_startElement(log->writer, tagName, numShaderAttribs, shaderAttribs) || in qpTestLog_writeShader()
1064 !qpXmlWriter_writeStringElement(log->writer, "ShaderSource", sourceStr) || in qpTestLog_writeShader()
1065 !qpXmlWriter_writeStringElement(log->writer, "InfoLog", infoLog) || in qpTestLog_writeShader()
1066 !qpXmlWriter_endElement(log->writer, tagName)) in qpTestLog_writeShader()
1069 deMutex_unlock(log->lock); in qpTestLog_writeShader()
1073 deMutex_unlock(log->lock); in qpTestLog_writeShader()
1078 * \brief Start writing a set of EGL configurations into the log.
1080 deBool qpTestLog_startEglConfigSet (qpTestLog* log, const char* name, const char* description) in qpTestLog_startEglConfigSet() argument
1085 DE_ASSERT(log && name); in qpTestLog_startEglConfigSet()
1086 deMutex_lock(log->lock); in qpTestLog_startEglConfigSet()
1093 if (!qpXmlWriter_startElement(log->writer, "EglConfigSet", numAttribs, attribs)) in qpTestLog_startEglConfigSet()
1096 deMutex_unlock(log->lock); in qpTestLog_startEglConfigSet()
1100 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_EGLCONFIGSET)); in qpTestLog_startEglConfigSet()
1102 deMutex_unlock(log->lock); in qpTestLog_startEglConfigSet()
1109 deBool qpTestLog_endEglConfigSet (qpTestLog* log) in qpTestLog_endEglConfigSet() argument
1111 DE_ASSERT(log); in qpTestLog_endEglConfigSet()
1112 deMutex_lock(log->lock); in qpTestLog_endEglConfigSet()
1115 if (!qpXmlWriter_endElement(log->writer, "EglConfigSet")) in qpTestLog_endEglConfigSet()
1118 deMutex_unlock(log->lock); in qpTestLog_endEglConfigSet()
1122 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_EGLCONFIGSET); in qpTestLog_endEglConfigSet()
1124 deMutex_unlock(log->lock); in qpTestLog_endEglConfigSet()
1132 deBool qpTestLog_writeEglConfig (qpTestLog* log, const qpEglConfigInfo* config) in qpTestLog_writeEglConfig() argument
1137 DE_ASSERT(log && config); in qpTestLog_writeEglConfig()
1138 deMutex_lock(log->lock); in qpTestLog_writeEglConfig()
1172 if (!qpXmlWriter_startElement(log->writer, "EglConfig", numAttribs, attribs) || in qpTestLog_writeEglConfig()
1173 !qpXmlWriter_endElement(log->writer, "EglConfig")) in qpTestLog_writeEglConfig()
1176 deMutex_unlock(log->lock); in qpTestLog_writeEglConfig()
1180 deMutex_unlock(log->lock); in qpTestLog_writeEglConfig()
1185 * \brief Start section in log.
1186 * \param log qpTestLog instance
1191 deBool qpTestLog_startSection (qpTestLog* log, const char* name, const char* description) in qpTestLog_startSection() argument
1196 DE_ASSERT(log && name); in qpTestLog_startSection()
1197 deMutex_lock(log->lock); in qpTestLog_startSection()
1204 if (!qpXmlWriter_startElement(log->writer, "Section", numAttribs, attribs)) in qpTestLog_startSection()
1207 deMutex_unlock(log->lock); in qpTestLog_startSection()
1211 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_SECTION)); in qpTestLog_startSection()
1213 deMutex_unlock(log->lock); in qpTestLog_startSection()
1218 * \brief End section in log.
1219 * \param log qpTestLog instance
1222 deBool qpTestLog_endSection (qpTestLog* log) in qpTestLog_endSection() argument
1224 DE_ASSERT(log); in qpTestLog_endSection()
1225 deMutex_lock(log->lock); in qpTestLog_endSection()
1228 if (!qpXmlWriter_endElement(log->writer, "Section")) in qpTestLog_endSection()
1231 deMutex_unlock(log->lock); in qpTestLog_endSection()
1235 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_SECTION); in qpTestLog_endSection()
1237 deMutex_unlock(log->lock); in qpTestLog_endSection()
1242 * \brief Write OpenCL compute kernel source into the log.
1244 deBool qpTestLog_writeKernelSource (qpTestLog* log, const char* source) in qpTestLog_writeKernelSource() argument
1246 const char* sourceStr = (log->flags & QP_TEST_LOG_EXCLUDE_SHADER_SOURCES) != 0 ? "" : source; in qpTestLog_writeKernelSource()
1248 DE_ASSERT(log); in qpTestLog_writeKernelSource()
1249 deMutex_lock(log->lock); in qpTestLog_writeKernelSource()
1251 if (!qpXmlWriter_writeStringElement(log->writer, "KernelSource", sourceStr)) in qpTestLog_writeKernelSource()
1254 deMutex_unlock(log->lock); in qpTestLog_writeKernelSource()
1258 deMutex_unlock(log->lock); in qpTestLog_writeKernelSource()
1263 * \brief Write a SPIR-V module assembly source into the log.
1265 deBool qpTestLog_writeSpirVAssemblySource (qpTestLog* log, const char* source) in qpTestLog_writeSpirVAssemblySource() argument
1267 const char* const sourceStr = (log->flags & QP_TEST_LOG_EXCLUDE_SHADER_SOURCES) != 0 ? "" : source; in qpTestLog_writeSpirVAssemblySource()
1269 deMutex_lock(log->lock); in qpTestLog_writeSpirVAssemblySource()
1271 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SHADERPROGRAM); in qpTestLog_writeSpirVAssemblySource()
1273 if (!qpXmlWriter_writeStringElement(log->writer, "SpirVAssemblySource", sourceStr)) in qpTestLog_writeSpirVAssemblySource()
1276 deMutex_unlock(log->lock); in qpTestLog_writeSpirVAssemblySource()
1280 deMutex_unlock(log->lock); in qpTestLog_writeSpirVAssemblySource()
1285 * \brief Write OpenCL kernel compilation results into the log
1287 deBool qpTestLog_writeCompileInfo (qpTestLog* log, const char* name, const char* description, deBoo… in qpTestLog_writeCompileInfo() argument
1292 DE_ASSERT(log && name && description && infoLog); in qpTestLog_writeCompileInfo()
1293 deMutex_lock(log->lock); in qpTestLog_writeCompileInfo()
1299 if (!qpXmlWriter_startElement(log->writer, "CompileInfo", numAttribs, attribs) || in qpTestLog_writeCompileInfo()
1300 !qpXmlWriter_writeStringElement(log->writer, "InfoLog", infoLog) || in qpTestLog_writeCompileInfo()
1301 !qpXmlWriter_endElement(log->writer, "CompileInfo")) in qpTestLog_writeCompileInfo()
1304 deMutex_unlock(log->lock); in qpTestLog_writeCompileInfo()
1308 deMutex_unlock(log->lock); in qpTestLog_writeCompileInfo()
1312 deBool qpTestLog_startSampleList (qpTestLog* log, const char* name, const char* description) in qpTestLog_startSampleList() argument
1317 DE_ASSERT(log && name && description); in qpTestLog_startSampleList()
1318 deMutex_lock(log->lock); in qpTestLog_startSampleList()
1323 if (!qpXmlWriter_startElement(log->writer, "SampleList", numAttribs, attribs)) in qpTestLog_startSampleList()
1326 deMutex_unlock(log->lock); in qpTestLog_startSampleList()
1330 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_SAMPLELIST)); in qpTestLog_startSampleList()
1332 deMutex_unlock(log->lock); in qpTestLog_startSampleList()
1336 deBool qpTestLog_startSampleInfo (qpTestLog* log) in qpTestLog_startSampleInfo() argument
1338 DE_ASSERT(log); in qpTestLog_startSampleInfo()
1339 deMutex_lock(log->lock); in qpTestLog_startSampleInfo()
1341 if (!qpXmlWriter_startElement(log->writer, "SampleInfo", 0, DE_NULL)) in qpTestLog_startSampleInfo()
1344 deMutex_unlock(log->lock); in qpTestLog_startSampleInfo()
1348 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_SAMPLEINFO)); in qpTestLog_startSampleInfo()
1350 deMutex_unlock(log->lock); in qpTestLog_startSampleInfo()
1354 deBool qpTestLog_writeValueInfo (qpTestLog* log, const char* name, const char* description, const c… in qpTestLog_writeValueInfo() argument
1360 DE_ASSERT(log && name && description && tagName); in qpTestLog_writeValueInfo()
1361 deMutex_lock(log->lock); in qpTestLog_writeValueInfo()
1363 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SAMPLEINFO); in qpTestLog_writeValueInfo()
1372 if (!qpXmlWriter_startElement(log->writer, "ValueInfo", numAttribs, attribs) || in qpTestLog_writeValueInfo()
1373 !qpXmlWriter_endElement(log->writer, "ValueInfo")) in qpTestLog_writeValueInfo()
1376 deMutex_unlock(log->lock); in qpTestLog_writeValueInfo()
1380 deMutex_unlock(log->lock); in qpTestLog_writeValueInfo()
1384 deBool qpTestLog_endSampleInfo (qpTestLog* log) in qpTestLog_endSampleInfo() argument
1386 DE_ASSERT(log); in qpTestLog_endSampleInfo()
1387 deMutex_lock(log->lock); in qpTestLog_endSampleInfo()
1389 if (!qpXmlWriter_endElement(log->writer, "SampleInfo")) in qpTestLog_endSampleInfo()
1392 deMutex_unlock(log->lock); in qpTestLog_endSampleInfo()
1396 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_SAMPLEINFO); in qpTestLog_endSampleInfo()
1398 deMutex_unlock(log->lock); in qpTestLog_endSampleInfo()
1402 deBool qpTestLog_startSample (qpTestLog* log) in qpTestLog_startSample() argument
1404 DE_ASSERT(log); in qpTestLog_startSample()
1405 deMutex_lock(log->lock); in qpTestLog_startSample()
1407 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SAMPLELIST); in qpTestLog_startSample()
1409 if (!qpXmlWriter_startElement(log->writer, "Sample", 0, DE_NULL)) in qpTestLog_startSample()
1412 deMutex_unlock(log->lock); in qpTestLog_startSample()
1416 DE_ASSERT(ContainerStack_push(&log->containerStack, CONTAINERTYPE_SAMPLE)); in qpTestLog_startSample()
1418 deMutex_unlock(log->lock); in qpTestLog_startSample()
1422 deBool qpTestLog_writeValueFloat (qpTestLog* log, double value) in qpTestLog_writeValueFloat() argument
1427 deMutex_lock(log->lock); in qpTestLog_writeValueFloat()
1429 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SAMPLE); in qpTestLog_writeValueFloat()
1431 if (!qpXmlWriter_writeStringElement(log->writer, "Value", &tmpString[0])) in qpTestLog_writeValueFloat()
1434 deMutex_unlock(log->lock); in qpTestLog_writeValueFloat()
1438 deMutex_unlock(log->lock); in qpTestLog_writeValueFloat()
1442 deBool qpTestLog_writeValueInteger (qpTestLog* log, deInt64 value) in qpTestLog_writeValueInteger() argument
1447 deMutex_lock(log->lock); in qpTestLog_writeValueInteger()
1449 DE_ASSERT(ContainerStack_getTop(&log->containerStack) == CONTAINERTYPE_SAMPLE); in qpTestLog_writeValueInteger()
1451 if (!qpXmlWriter_writeStringElement(log->writer, "Value", &tmpString[0])) in qpTestLog_writeValueInteger()
1454 deMutex_unlock(log->lock); in qpTestLog_writeValueInteger()
1458 deMutex_unlock(log->lock); in qpTestLog_writeValueInteger()
1462 deBool qpTestLog_endSample (qpTestLog* log) in qpTestLog_endSample() argument
1464 DE_ASSERT(log); in qpTestLog_endSample()
1465 deMutex_lock(log->lock); in qpTestLog_endSample()
1467 if (!qpXmlWriter_endElement(log->writer, "Sample")) in qpTestLog_endSample()
1470 deMutex_unlock(log->lock); in qpTestLog_endSample()
1474 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_SAMPLE); in qpTestLog_endSample()
1476 deMutex_unlock(log->lock); in qpTestLog_endSample()
1480 deBool qpTestLog_endSampleList (qpTestLog* log) in qpTestLog_endSampleList() argument
1482 DE_ASSERT(log); in qpTestLog_endSampleList()
1483 deMutex_lock(log->lock); in qpTestLog_endSampleList()
1485 if (!qpXmlWriter_endElement(log->writer, "SampleList")) in qpTestLog_endSampleList()
1488 deMutex_unlock(log->lock); in qpTestLog_endSampleList()
1492 DE_ASSERT(ContainerStack_pop(&log->containerStack) == CONTAINERTYPE_SAMPLELIST); in qpTestLog_endSampleList()
1494 deMutex_unlock(log->lock); in qpTestLog_endSampleList()
1498 deUint32 qpTestLog_getLogFlags (const qpTestLog* log) in qpTestLog_getLogFlags() argument
1500 DE_ASSERT(log); in qpTestLog_getLogFlags()
1501 return log->flags; in qpTestLog_getLogFlags()