[Mesa-dev] [PATCH] i965/fs: don't do IR validation in release mode

Thomas Helland thomashelland90 at gmail.com
Tue May 23 10:44:05 UTC 2017


This looks to be in line with what I've seen with my profiling.
I was wondering why we where doing validation when
debug was not enabled.

Reviewed-by: Thomas Helland <thomashelland90 at gmail.com>

2017-05-22 5:46 GMT+02:00 Connor Abbott <cwabbott0 at gmail.com>:
> Surprisingly, profiling shows that this takes quite a lot of time. So
> turn it off when building in release mode, just like all the other
> validation passes we do.
>
> Difference at 95.0% confidence
>         -82.5956 +/- 11.46
>         -7.68394% +/- 1.06613%
>         (Student's t, pooled s = 15.8735)
>
> Signed-off-by: Connor Abbott <cwabbott0 at gmail.com>
> ---
>  src/intel/compiler/brw_fs_validate.cpp | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/src/intel/compiler/brw_fs_validate.cpp b/src/intel/compiler/brw_fs_validate.cpp
> index 676942c..cdccf0f 100644
> --- a/src/intel/compiler/brw_fs_validate.cpp
> +++ b/src/intel/compiler/brw_fs_validate.cpp
> @@ -41,6 +41,7 @@
>  void
>  fs_visitor::validate()
>  {
> +#ifdef DEBUG
>     foreach_block_and_inst (block, fs_inst, inst, cfg) {
>        if (inst->dst.file == VGRF) {
>           fsv_assert(inst->dst.offset / REG_SIZE + regs_written(inst) <=
> @@ -54,4 +55,5 @@ fs_visitor::validate()
>           }
>        }
>     }
> +#endif
>  }
> --
> 2.9.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list