Module: Mesa Branch: master Commit: d221f70299cc4b14316fe83eeb5ae28797421a63 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=d221f70299cc4b14316fe83eeb5ae28797421a63
Author: Jason Ekstrand <[email protected]> Date: Mon May 18 14:26:30 2020 -0500 nir: Add documentation for each jump instruction type Reviewed-by: Alyssa Rosenzweig <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5101> --- src/compiler/nir/nir.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h index dec20d33fd3..ca799c540a1 100644 --- a/src/compiler/nir/nir.h +++ b/src/compiler/nir/nir.h @@ -2223,8 +2223,26 @@ typedef struct { } nir_load_const_instr; typedef enum { + /** Return from a function + * + * This instruction is a classic function return. It jumps to + * nir_function_impl::end_block. No return value is provided in this + * instruction. Instead, the function is expected to write any return + * data to a deref passed in from the caller. + */ nir_jump_return, + + /** Break out of the inner-most loop + * + * This has the same semantics as C's "break" statement. + */ nir_jump_break, + + /** Jump back to the top of the inner-most loop + * + * This has the same semantics as C's "continue" statement assuming that a + * NIR loop is implemented as "while (1) { body }". + */ nir_jump_continue, } nir_jump_type; _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
