Ensure that multi-threading is disabled when enabling IRPrinting with module scope
This is avoid the user to shoot themselves in the foot and encounter
strange crashes that are confusing until one run with TSAN.
Differential Revision: https://reviews.llvm.org/D75399