From the code there, it looks that the pardiso structure pt, iparm, etcshared by the different threadings. Actually each threading will have its own structure.
Some more clarification that may be helpful to use the functions. There are 4 types of using PARDISO solving steps there:
1. Calling PARDISO with single right hand side. Works fine.
2. Calling PARDISO from parallel region, supplying each thread with one right hand side and the same handle. This works incorrectly indeed, because of the same handle. BTW, our documentation does not say PARDISO is thread safe when called with the same handle from multiple threads.
3. Calling PARDISO from sequential code with multiple right hand sides. This uses internal PARDISO parallelization and works fine as expected. This is the suggested usage model for multiple right hand sides.
4. Calling PARDISO from parallel region with _same_ multiple right hand sides. This code is incorrect, and it would not work correctly even if PARDISO was thread safe simply because there is a data race in the use of output (solution) vector.
Users should only use 1st and 3rd usage models. If user wants to solve systems with multiple right hand sides, he or she should consider gathering right hand sides in a single array and call only one instance of PARDISO solving step with multiple right hand sides. If gathering right hand sides is impossible, user must make sure only one instance of PARDISO is running solving step with the same handle.