diff options
author | Jason Ekstrand <[email protected]> | 2015-09-14 12:25:28 -0700 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2015-09-17 08:16:01 -0700 |
commit | ddffe30f404b7dffef2b90879023433ecc7df3e3 (patch) | |
tree | 13b2b1e77ecf7f2e16a7ebc0a4a27338ed4331f1 | |
parent | 8ecaef967d6f2775bf7114d857baf3aaa13643a7 (diff) |
nir: Add comments to nir_index_instrs and nir_index_ssa_defs
The provided indices have the very nice property that if A dominates B then
A->index <= B->index. We should document that somewhere.
Reviewed-by: Kenneth Graunke <[email protected]>
-rw-r--r-- | src/glsl/nir/nir.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c index 1ff8f217407..23071eff65b 100644 --- a/src/glsl/nir/nir.c +++ b/src/glsl/nir/nir.c @@ -1427,6 +1427,10 @@ index_ssa_block(nir_block *block, void *state) return true; } +/** + * The indices are applied top-to-bottom which has the very nice property + * that, if A dominates B, then A->index <= B->index. + */ void nir_index_ssa_defs(nir_function_impl *impl) { @@ -1445,6 +1449,10 @@ index_instrs_block(nir_block *block, void *state) return true; } +/** + * The indices are applied top-to-bottom which has the very nice property + * that, if A dominates B, then A->index <= B->index. + */ unsigned nir_index_instrs(nir_function_impl *impl) { |