From: Eduardo Lima Mitev Date: Tue, 16 Jun 2015 18:25:55 +0000 (+0200) Subject: i965/nir/vec4: Implement loop statements (nir_cf_node_loop) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=afe085a0ca01f659c69456018e5f5076c9dde47d;p=mesa.git i965/nir/vec4: Implement loop statements (nir_cf_node_loop) This is taken as-is from fs_nir. Reviewed-by: Jason Ekstrand --- diff --git a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp index 7ce571a2261..763c69a9521 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp @@ -302,7 +302,11 @@ vec4_visitor::nir_emit_if(nir_if *if_stmt) void vec4_visitor::nir_emit_loop(nir_loop *loop) { - /* @TODO: Not yet implemented */ + emit(BRW_OPCODE_DO); + + nir_emit_cf_list(&loop->body); + + emit(BRW_OPCODE_WHILE); } void