#include "si_shader_internal.h"
#include "sid.h"
#include "ac_shadowed_regs.h"
+#include "compiler/nir/nir.h"
#include "util/disk_cache.h"
#include "util/u_cpu_detect.h"
#include "util/u_log.h"
num_comp_lo_threads = 1;
}
+#ifndef NDEBUG
+ nir_process_debug_variable();
+
+ /* Use a single compilation thread if NIR printing is enabled to avoid
+ * multiple shaders being printed at the same time.
+ */
+ if (NIR_DEBUG(PRINT)) {
+ num_comp_hi_threads = 1;
+ num_comp_lo_threads = 1;
+ }
+#endif
+
num_comp_hi_threads = MIN2(num_comp_hi_threads, ARRAY_SIZE(sscreen->compiler));
num_comp_lo_threads = MIN2(num_comp_lo_threads, ARRAY_SIZE(sscreen->compiler_lowp));