<html><head><meta http-equiv="content-type" content="text/html; charset=us-ascii"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;"><div><br></div> Ok, two things are being changed at the same time: the version of PETSc and the version of Visual Studio. <div><br></div><div> Could you please try with the new Visual Studio version but the same older PETSc version? If that works could you try with the old Visual Studio version but the new PETSc version? </div><div><br></div><div> Barry</div><div><br></div><div><br><div><br><blockquote type="cite"><div>On Sep 18, 2023, at 6:26 PM, Thuc Bui <bui@calcreek.com> wrote:</div><br class="Apple-interchange-newline"><div><meta charset="UTF-8"><div class="WordSection1" style="page: WordSection1; caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 18px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Dear Petsc users and experts,<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">If someone can direct me how to track this bug, I would really appreciate it.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">The Petsc DLL library version 3.19.4 was built on Windows 10 with Visual Studio 2022, and with Microsoft MPI 10.1.2 and Intel MKL 2020.3.279. The same code works fine with Petsc 3.18.6 using the same versions of MS MPI and Intel MKL, and built with Visual Studio 2019.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">When my code calls PetscCall(KSPSolve(...)), it gets to PetscCall(KSPGMRESCycle(...)), PetscCall(VecNormalize(VEC_VV(0), &res)), PetscCall(VecNorm(x, NORM_2, &norm)) and then crashes in VecNorm_Seq() at:<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"> PetscCallBLAS("BLASdot", ztmp[type == NORM_1_AND_2] = PetscSqrtReal(PetscRealPart(BLASdot_(&bn, xx, &one, xx, &one))));<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">I tried to step into BLASdot_, but was unable to. I assume BLASdot_ belong to Intel MKL, and its library does not contain debug information. After the code exits, the errors are shown below the hash line.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Should I install the latest Intel MKL to work with Petsc 3.19.4?<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Many thanks in advance for your help,<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Thuc Bui<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Senior R&D Engineer<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">Calabazas Creek Research, Inc<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">(650) 948-5361<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">###############################################<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: ------------------------------------------------------------------------<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: or see<span class="Apple-converted-space"> </span><a href="https://petsc.org/release/faq/#valgrind" style="color: purple; text-decoration: underline;">https://petsc.org/release/faq/#valgrind</a><span class="Apple-converted-space"> </span>and<span class="Apple-converted-space"> </span><a href="https://petsc.org/release/faq/" style="color: purple; text-decoration: underline;">https://petsc.org/release/faq/</a><o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: --------------------- Stack Frames ------------------------------------<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: The line numbers in the error traceback are not always exact.<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #1 BLASdot()<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #2 VecNorm_Seq() at D:\Users\bbwannabe\Documents\Petsc\latest\src\vec\vec\impls\seq\bvec2.c:213<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #3 VecNorm() at D:\Users\bbwannabe\Documents\Petsc\latest\src\vec\vec\interface\rvector.c:237<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #4 VecNormalize() at D:\Users\bbwannabe\Documents\Petsc\latest\src\vec\vec\interface\rvector.c:318<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #5 KSPGMRESCycle() at D:\Users\bbwannabe\Documents\Petsc\latest\src\ksp\ksp\impls\gmres\gmres.c:110<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #6 KSPSolve_GMRES() at D:\Users\bbwannabe\Documents\Petsc\latest\src\ksp\ksp\impls\gmres\gmres.c:227<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #7 KSPSolve_Private() at D:\Users\bbwannabe\Documents\Petsc\latest\src\ksp\ksp\interface\itfunc.c:898<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0]PETSC ERROR: #8 KSPSolve() at D:\Users\bbwannabe\Documents\Petsc\latest\src\ksp\ksp\interface\itfunc.c:1070<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">job aborted:<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[ranks] message<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;"><o:p> </o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">[0] application aborted<o:p></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;">aborting MPI_COMM_WORLD (comm=0x44000000), error 59, comm rank 0</div></div></div></blockquote></div><br></div></body></html>