Instructions for testing Inspector ---------------------------------- 0. Log to DevClould (needs instructions from day #1) --------------------------------------------------- reserve node (no gpu needed): $ qsub -I -l nodes=1:ppn=2 check node $ cpuinfo -g example output: ===== Processor composition ===== Processor name : Intel(R) Xeon(R) Gold 6128 Packages(sockets) : 2 Cores : 12 Processors(CPUs) : 24 Cores per package : 6 Threads per core : 2 1. build example (matmul with threading error) ---------------------------------------------- $ cp /data/comp/workshop/matmul_broken.c . $ 2. run without tools -------------------- $ ./matmul.x Order 100 multiplication in 0.050215 seconds 24 threads Order 100 multiplication at 39.828732 mflops Errors in multiplication: 14374856925.000000 all done Internal checks indicate errors! 3. run with inspector --------------------- $ inspxe-cl -c ti3 ./matmul.x Collection started. To stop the collection, either press CTRL-C or enter from another console window: inspxe-cl -r /home/u48655/Workshops/HLRS/demo/r000ti3 -command stop. Warning: One or more threads in the application accessed the stack of another thread. This may indicate one or more bugs in your application. Setting the Inspector to detect data races on stack accesses and running another analysis may help you locate these and other bugs. Order 100 multiplication in 3.378343 seconds 24 threads Order 100 multiplication at 0.592006 mflops Errors in multiplication: 10976725125.000000 all done 1 new problem(s) found 1 Data race problem(s) detected 4. view issue with command line ------------------------------- $ inspxe-cl -report=problems -report-all -r P1.27: Error: Data race: New /home/u48655/Workshops/HLRS/demo/matmul_broken.c(74): Error X57: Write: Function .omp_outlined._debug__: Module /home/u48655/Workshops/HLRS/demo/matmul.x Code snippet: 72 for(k=0;k74 tmp += *(A+(i*Ndim+k)) * *(B+(k*Pdim+j)); 75 } 76 *(C+(i*Ndim+j)) = tmp; Stack (1 of 1 instance(s)) >matmul.x!.omp_outlined._debug__ - /home/u48655/Workshops/HLRS/demo/matmul_broken.c:74 matmul.x!.omp_outlined - /home/u48655/Workshops/HLRS/demo/matmul_broken.c:66 /home/u48655/Workshops/HLRS/demo/matmul_broken.c(70): Error X58: Write: Function .omp_outlined._debug__: Module /home/u48655/Workshops/HLRS/demo/matmul.x Code snippet: 68 for (j=0; j70 tmp = 0.0; 71 72 for(k=0;k must be an issue with tmp variable 5. create archive ----------------- $ inspxe-cl -export -archive-name matmul.inspxez -include-sources -r move matmul.inspxez to another computer with Inspector GUI and open it example taken from: https://github.com/tgmattso/OpenMP_intro_tutorial.git