On Mon, Dec 14, 2015 at 3:34 PM, Ian Romanick wrote:
> From: Ian Romanick
>
> The guts were removed in dfb3abba. It has been almost exactly a year,
> so I dont think we're going to "decide we want [predication] back."
Yeah, I think that bridge is burned.
> Silences several "unused parameter" warnings:
>
> nir/nir.c: In function ‘visit_call_src’:
> nir/nir.c:1052:32: warning: unused parameter ‘instr’ [-Wunused-parameter]
> visit_call_src(nir_call_instr *instr, nir_foreach_src_cb cb, void *state)
> ^
> nir/nir.c:1052:58: warning: unused parameter ‘cb’ [-Wunused-parameter]
> visit_call_src(nir_call_instr *instr, nir_foreach_src_cb cb, void *state)
> ^
> nir/nir.c:1052:68: warning: unused parameter ‘state’ [-Wunused-parameter]
> visit_call_src(nir_call_instr *instr, nir_foreach_src_cb cb, void *state)
> ^
> nir/nir.c: In function ‘visit_load_const_src’:
> nir/nir.c:1058:44: warning: unused parameter ‘instr’ [-Wunused-parameter]
> visit_load_const_src(nir_load_const_instr *instr, nir_foreach_src_cb cb,
> ^
> nir/nir.c:1058:70: warning: unused parameter ‘cb’ [-Wunused-parameter]
> visit_load_const_src(nir_load_const_instr *instr, nir_foreach_src_cb cb,
> ^
> nir/nir.c:1059:28: warning: unused parameter ‘state’ [-Wunused-parameter]
> void *state)
> ^
>
> Signed-off-by: Ian Romanick
> Cc: Jason Ekstrand
> Cc: Connor Abbott
> ---
> src/glsl/nir/nir.c | 17 -
> 1 file changed, 17 deletions(-)
>
> diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
> index 6bae05b..8c86135 100644
> --- a/src/glsl/nir/nir.c
> +++ b/src/glsl/nir/nir.c
> @@ -1049,19 +1049,6 @@ visit_intrinsic_src(nir_intrinsic_instr *instr,
> nir_foreach_src_cb cb,
> }
>
> static bool
> -visit_call_src(nir_call_instr *instr, nir_foreach_src_cb cb, void *state)
> -{
> - return true;
> -}
> -
> -static bool
> -visit_load_const_src(nir_load_const_instr *instr, nir_foreach_src_cb cb,
> - void *state)
> -{
> - return true;
> -}
> -
> -static bool
> visit_phi_src(nir_phi_instr *instr, nir_foreach_src_cb cb, void *state)
> {
> nir_foreach_phi_src(instr, src) {
> @@ -1117,12 +1104,8 @@ nir_foreach_src(nir_instr *instr, nir_foreach_src_cb
> cb, void *state)
> return false;
>break;
> case nir_instr_type_call:
> - if (!visit_call_src(nir_instr_as_call(instr), cb, state))
> - return false;
Please at least add a "Call instructions have no regular sources" comment.
>break;
> case nir_instr_type_load_const:
> - if (!visit_load_const_src(nir_instr_as_load_const(instr), cb, state))
> - return false;
Same for constant loads
With that added,
Reviewed-by: Jason Ekstrand
>break;
> case nir_instr_type_phi:
>if (!visit_phi_src(nir_instr_as_phi(instr), cb, state))
> --
> 2.5.0
>
> ___
> mesa-dev mailing list
> mesa-dev@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev