[Mesa-dev] [PATCH 1/2] i965/fs: move first shader dump to the beginning of optimize
Alejandro PiƱeiro
apinheiro at igalia.com
Tue May 23 10:52:52 UTC 2017
Seems more natural, as this is the real starting point. It also
allows to dump the shader before the first validate, so we could
check the full shader that is failing to validate (instead of
just the wrong line).
---
src/intel/compiler/brw_fs.cpp | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/intel/compiler/brw_fs.cpp b/src/intel/compiler/brw_fs.cpp
index 329c15b..382a0fe 100644
--- a/src/intel/compiler/brw_fs.cpp
+++ b/src/intel/compiler/brw_fs.cpp
@@ -5626,6 +5626,14 @@ fs_visitor::opt_drop_redundant_mov_to_flags()
void
fs_visitor::optimize()
{
+ if (unlikely(INTEL_DEBUG & DEBUG_OPTIMIZER)) {
+ char filename[64];
+ snprintf(filename, 64, "%s%d-%s-00-00-start",
+ stage_abbrev, dispatch_width, nir->info.name);
+
+ backend_shader::dump_instructions(filename);
+ }
+
/* Start by validating the shader we currently have. */
validate();
@@ -5668,14 +5676,6 @@ fs_visitor::optimize()
this_progress; \
})
- if (unlikely(INTEL_DEBUG & DEBUG_OPTIMIZER)) {
- char filename[64];
- snprintf(filename, 64, "%s%d-%s-00-00-start",
- stage_abbrev, dispatch_width, nir->info.name);
-
- backend_shader::dump_instructions(filename);
- }
-
bool progress = false;
int iteration = 0;
int pass_num = 0;
--
2.9.3
More information about the mesa-dev
mailing list