On 12/15/2014 08:30 PM, Ian Romanick wrote:
> On 12/15/2014 08:04 AM, Eduardo Lima Mitev wrote:
>>
>> Since the maximum supported precision for stencil buffers is 8 bits, mask
>> values should be initialized to 2^8 - 1 = 0xFF.
>>
>> Currently, these masks are initialized to max unsigned integer (~0
https://bugs.freedesktop.org/show_bug.cgi?id=86944
José Fonseca changed:
What|Removed |Added
Assignee|mesa-dev@lists.freedesktop. |jfons...@vmware.com
|or
On Tue, Dec 16, 2014 at 5:50 AM, Brian Paul wrote:
> ---
> src/mesa/main/enums.h | 11 +++
> src/mesa/main/samplerobj.h| 9 +
> src/mesa/main/texenvprogram.h | 11 +++
> src/mesa/main/texobj.h| 10 ++
> 4 files changed, 41 insertions(+)
>
> dif
On Mon, 2014-12-15 at 10:19 -0800, Jason Ekstrand wrote:
>
>
> On Mon, Dec 15, 2014 at 3:12 AM, Iago Toral wrote:
> On Fri, 2014-12-12 at 11:36 -0800, Jason Ekstrand wrote:
> >
> >
> > On Tue, Dec 9, 2014 at 4:07 AM, Iago Toral Quiroga
>
> > wrote
---
src/glsl/nir/nir_lower_system_values.c | 15 ++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/src/glsl/nir/nir_lower_system_values.c
b/src/glsl/nir/nir_lower_system_values.c
index 7bb02a7..d1b4d26 100644
--- a/src/glsl/nir/nir_lower_system_values.c
+++ b/src/glsl/
Previously, lower_atomics was non-SSA only. We assert-failed if the
destination of an atomic operation intrinsic was an SSA def and we used
temporary registers for computing offsets. This commit changes both of
these behaviors. We now use SSA values for computing offsets (so we can
optimize them
As it was, we weren't ever using load_const in a non-SSA way. This allows
us to substantially simplify the load_const instruction. If we ever need a
non-SSA constant load, we can do a load_const and an imov.
---
src/glsl/nir/glsl_to_nir.cpp | 12 ++--
src/glsl/nir/nir.c
This is no longer needed because it's now part of the algebraic
optimization pass
---
src/glsl/Makefile.sources| 1 -
src/glsl/nir/nir_opt_peephole_ffma.c | 189 ---
2 files changed, 190 deletions(-)
delete mode 100644 src/glsl/nir/nir_opt_peephole_ff
Previously, the condition was a scalar that applied to all components
simultaneously. As of this commit, the condition is a vector and each
component is switched seperately.
---
src/glsl/nir/nir_lower_variables.c | 1 +
src/glsl/nir/nir_opcodes.h | 5 ++---
src/glsl/nir/nir_
In GLSL-to-NIR we were just setting the base index to 0 whenever there was
an indirect so having it expressed as a sum makes no sense. Also, while a
base offset may make sense for the memory location (first element in the
array, etc.) it makes less sense for the actual uniform buffer index. This
---
src/glsl/nir/nir.c | 11 +++
src/glsl/nir/nir.h | 10 ++
src/glsl/nir/nir_print.c| 4
src/glsl/nir/nir_validate.c | 3 +++
4 files changed, 28 insertions(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 60c9cff..8bcc64a 100644
--- a/sr
---
src/glsl/nir/nir.c | 5 ++---
src/glsl/nir/nir.h | 3 ++-
src/glsl/nir/nir_lower_variables.c | 11 +--
src/glsl/nir/nir_to_ssa.c | 5 ++---
4 files changed, 11 insertions(+), 13 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir
We stopped generating predicates in glsl_to_nir some time ago. Right now,
it's all dead untested code that I'm not convinced always worked in the
first place. If we decide we want them back, we can revert this patch.
---
src/glsl/nir/nir.c | 35 -
src/glsl/nir/nir.
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 060912e..2cf9780 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++ b/src/
Previously, we were just iterating over the program "in order" which
kind-of approximates a DFS, but not really. In particular, we got the
following case wrong:
loop {
a = 3;
if (foo) {
a = 5;
} else {
break;
}
use(a);
}
where use(a) would get 3 instead of 5 because of
This commit renames nir_instr_as_texture to nir_instr_as_tex and renames
nir_instr_type_texture to nir_instr_type_tex to be consistent with
nir_tex_instr.
---
src/glsl/nir/glsl_to_nir.cpp | 4 ++--
src/glsl/nir/nir.c | 10 +-
src/glsl/nir/nir.h
Before, we were using foreach_dest and switching on whether the destination
was an SSA value. This works, except not all destinations are SSA values
so we have to special-case ssa_undef instructions. Now that we have a
foreach_ssa_def function, we can iterate over all of the register
destinations
This commit builds on the nir_search.h infastructure by adds a bit of
python code that makes it stupid easy to write an algebraic transformation
pass. The nir_algebraic.py file contains four python classes that
correspond directly to the datastructures in nir_search.c and allow you to
easily gener
---
src/glsl/nir/nir_from_ssa.c | 3 +++
src/glsl/nir/nir_lower_atomics.c| 5 -
src/glsl/nir/nir_lower_io.c | 3 +++
src/glsl/nir/nir_lower_locals_to_regs.c | 3 +++
src/glsl/nir/nir_lower_system_values.c | 2 ++
src/glsl/nir/nir_opt_constant_folding.c | 4
---
src/glsl/nir/nir_live_variables.c | 32 +---
1 file changed, 13 insertions(+), 19 deletions(-)
diff --git a/src/glsl/nir/nir_live_variables.c
b/src/glsl/nir/nir_live_variables.c
index 7d99a06..13306b3 100644
--- a/src/glsl/nir/nir_live_variables.c
+++ b/src/glsl/n
---
src/glsl/nir/nir_opt_constant_folding.c | 84 +
1 file changed, 76 insertions(+), 8 deletions(-)
diff --git a/src/glsl/nir/nir_opt_constant_folding.c
b/src/glsl/nir/nir_opt_constant_folding.c
index 3523713..e2b16e9 100644
--- a/src/glsl/nir/nir_opt_constant_fo
---
src/glsl/Makefile.sources| 1 +
src/glsl/nir/nir.h | 1 +
src/glsl/nir/nir_lower_to_source_mods.c | 181 +++
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 5 +
4 files changed, 188 insertions(+)
create mode 100644 src/glsl/
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 102 +++
1 file changed, 102 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 46d855d..67714ec 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++
This pass uses the previously built algebraic transformations framework and
should act as an example for anyone else wanting to make an algebraic
transformation pass for NIR.
---
src/glsl/Makefile.am | 10 -
src/glsl/Makefile.sources| 6 ++-
src/glsl/nir/ni
There are some functions whose destinations are SSA-only and so aren't a
nir_dest. This provides a function that is capable of iterating over the
SSA definitions defined by those functions. If you want registers, you
should use the old iterator.
---
src/glsl/nir/nir.c | 41 ++
---
src/glsl/nir/nir_lower_samplers.cpp | 149 ++--
1 file changed, 74 insertions(+), 75 deletions(-)
diff --git a/src/glsl/nir/nir_lower_samplers.cpp
b/src/glsl/nir/nir_lower_samplers.cpp
index d94183c..ece4dc3 100644
--- a/src/glsl/nir/nir_lower_samplers.cpp
+++
nir_metadata_dirty was a terrible name because the parameter it takes is
the metadata to be preserved. This is really confusing because it looks
like it's doing the opposite of what it is actually doing. Now it's named
sensibly.
---
src/glsl/nir/nir.c | 10 +-
src/gls
---
src/glsl/nir/nir_opcodes.h | 5 +
1 file changed, 5 insertions(+)
diff --git a/src/glsl/nir/nir_opcodes.h b/src/glsl/nir/nir_opcodes.h
index 35d4634..c8230b3 100644
--- a/src/glsl/nir/nir_opcodes.h
+++ b/src/glsl/nir/nir_opcodes.h
@@ -59,10 +59,15 @@
UNOP(fmov, nir_type_float)
UNOP(imov
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 24 ++--
1 file changed, 22 insertions(+), 2 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index c7610d1..f10a90d 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.c
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 77 ++--
1 file changed, 14 insertions(+), 63 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 4c1805d..46d855d 100644
--- a/src/mesa/drivers/dri/i965/brw
Previously, the casting operations were macros. While this is usually
fine, the casting macro used the input parameter twice leading to strange
behavior when you passed the result of another function into it. Since we
know the source and destination types explicitly, we don't loose anything
by ma
This framework provides a simple way to do simple search-and-replace
operations on NIR code. The nir_search.h header provides four simple data
structures for representing expressions: nir_value and four subtypes:
nir_variable, nir_constant, and nir_expression. An expression tree can
then be repr
---
src/glsl/nir/glsl_to_nir.cpp | 80 +++-
1 file changed, 79 insertions(+), 1 deletion(-)
diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp
index 088a8e9..7654972 100644
--- a/src/glsl/nir/glsl_to_nir.cpp
+++ b/src/glsl/nir/glsl_to_
---
src/glsl/nir/nir_validate.c | 26 ++
1 file changed, 26 insertions(+)
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c
index ee29fc3..6051784 100644
--- a/src/glsl/nir/nir_validate.c
+++ b/src/glsl/nir/nir_validate.c
@@ -325,10 +325,36 @@ validate
---
src/glsl/nir/nir.c | 19 +++
src/glsl/nir/nir.h | 1 +
2 files changed, 20 insertions(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index a4edc79..f5183ce 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1666,6 +1666,25 @@ nir_foreach_src(nir_instr *inst
---
src/glsl/nir/nir_intrinsics.h | 32 +++-
src/glsl/nir/nir_lower_io.c | 16 ++--
2 files changed, 21 insertions(+), 27 deletions(-)
diff --git a/src/glsl/nir/nir_intrinsics.h b/src/glsl/nir/nir_intrinsics.h
index 75bd12f..e66273d 100644
--- a/src/glsl/
---
src/glsl/nir/glsl_to_nir.cpp | 9 +++--
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp
index 7654972..5ead8cd 100644
--- a/src/glsl/nir/glsl_to_nir.cpp
+++ b/src/glsl/nir/glsl_to_nir.cpp
@@ -1041,19 +1041,16 @@ nir_
---
src/glsl/Makefile.sources| 1 +
src/glsl/nir/nir.h | 1 +
src/glsl/nir/nir_opt_constant_folding.c | 283 +++
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 2 +
4 files changed, 287 insertions(+)
create mode 100644 src/glsl/
We used to have the number of components built into the intrinsic. This
meant that all of our load/store intrinsics had vec1, vec2, vec3, and vec4
variants. This lead to piles of switch statements to generate the correct
texture names, and introspection to figure out the number of components.
We
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_lower_io.c | 388
3 files changed, 391 insertions(+)
create mode 100644 src/glsl/nir/nir_lower_io.c
diff --git a/src/glsl/Makefile.sources b/src/glsl/Makefi
With this commit, the GLSL IR -> NIR pass generates NIR in more-or-less SSA
form. It's SSA in the sense that it doesn't have any registers, but it
isn't really useful SSA because it still has a pile of load/store
intrinsics that we will need to get rid of.
---
src/glsl/nir/glsl_to_nir.cpp | 246 +
---
src/glsl/nir/nir.c | 9 -
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 07d7b94..a4edc79 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1004,13 +1004,12 @@ update_if_uses(nir_cf_node *node)
return;
---
src/glsl/Makefile.sources |1 -
src/glsl/nir/nir_lower_variables_scalar.c | 1249 -
2 files changed, 1250 deletions(-)
delete mode 100644 src/glsl/nir/nir_lower_variables_scalar.c
diff --git a/src/glsl/Makefile.sources b/src/glsl/Makefile.sourc
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h| 2 +
src/glsl/nir/nir_lower_global_vars_to_local.c | 107 ++
3 files changed, 110 insertions(+)
create mode 100644 src/glsl/nir/nir_lower_global_vars_to_local.c
di
---
src/glsl/nir/nir.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/glsl/nir/nir.h b/src/glsl/nir/nir.h
index b04a137..fc16cb5 100644
--- a/src/glsl/nir/nir.h
+++ b/src/glsl/nir/nir.h
@@ -155,7 +155,7 @@ typedef struct {
*
* \sa nir_variable_mode
This pass analizes all of the load/store operations and, when a variable is
never aliased (potentially used by an indirect operation), it is lowered
directly to an SSA value. This pass translates to SSA directly and does
not require any fixup by the original to-SSA pass.
---
src/glsl/Makefile.sou
This commit switches us over to the new variable lowering code which is
capable of properly handling lowering indirects as we go.
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 44 ++--
1 file changed, 25 insertions(+), 19 deletions(-)
diff --git a/src/mesa/drivers/dri
---
src/glsl/nir/nir_validate.c | 23 +++
1 file changed, 23 insertions(+)
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c
index 80faa15..b8ef802 100644
--- a/src/glsl/nir/nir_validate.c
+++ b/src/glsl/nir/nir_validate.c
@@ -337,6 +337,29 @@ validate_int
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_split_var_copies.c | 225
3 files changed, 228 insertions(+)
create mode 100644 src/glsl/nir/nir_split_var_copies.c
diff --git a/src/glsl/Makefile.s
---
src/glsl/nir/glsl_to_nir.cpp | 18 --
1 file changed, 12 insertions(+), 6 deletions(-)
diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp
index 754a81f..6870bd2 100644
--- a/src/glsl/nir/glsl_to_nir.cpp
+++ b/src/glsl/nir/glsl_to_nir.cpp
@@ -329,12 +329,1
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_lower_locals_to_regs.c | 313
3 files changed, 316 insertions(+)
create mode 100644 src/glsl/nir/nir_lower_locals_to_regs.c
diff --git a/src/gls
This is killing piglit. I'll leave the logging local
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 5 -
1 file changed, 5 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index f4656bc..0cd8fca 100644
--- a/src/mesa/drivers/dri/i
---
src/glsl/nir/nir_validate.c | 13 +
1 file changed, 13 insertions(+)
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c
index 8354aa3..80faa15 100644
--- a/src/glsl/nir/nir_validate.c
+++ b/src/glsl/nir/nir_validate.c
@@ -466,9 +466,22 @@ validate_phi_src(nir_p
---
src/glsl/nir/glsl_to_nir.cpp | 3 ++-
src/glsl/nir/nir.c| 10 +-
src/glsl/nir/nir.h| 7 ++-
src/glsl/nir/nir_lower_atomics.c | 2 +-
src/glsl/nir/nir_lower_samplers.cpp | 2 +-
src/glsl/nir/nir_lower_va
---
src/glsl/nir/nir.h | 9 +
src/glsl/nir/nir_print.c | 3 +++
2 files changed, 12 insertions(+)
diff --git a/src/glsl/nir/nir.h b/src/glsl/nir/nir.h
index f4db3f8..27e7e7a 100644
--- a/src/glsl/nir/nir.h
+++ b/src/glsl/nir/nir.h
@@ -625,9 +625,18 @@ typedef struct {
nir_variab
Instead, we give SSA definitions a temporary index of 0x if the
instruction does not have a block and a proper index when it actually gets
added to the list.
---
src/glsl/nir/nir.c | 42 ++
src/glsl/nir/nir.h | 5 ++--
---
src/glsl/nir/nir_opt_copy_propagate.c | 12
1 file changed, 12 insertions(+)
diff --git a/src/glsl/nir/nir_opt_copy_propagate.c
b/src/glsl/nir/nir_opt_copy_propagate.c
index b710181..1f81b17 100644
--- a/src/glsl/nir/nir_opt_copy_propagate.c
+++ b/src/glsl/nir/nir_opt_copy_propa
---
src/glsl/nir/nir_lower_samplers.cpp | 11 ++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/src/glsl/nir/nir_lower_samplers.cpp
b/src/glsl/nir/nir_lower_samplers.cpp
index e10456d..347c84a 100644
--- a/src/glsl/nir/nir_lower_samplers.cpp
+++ b/src/glsl/nir/nir_lower_sa
---
src/glsl/nir/nir.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 5d7d21a..cf238c1 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -536,6 +536,7 @@ static nir_deref_var *
copy_deref_var(void *mem_ctx, nir_deref
Previously, we used a string name. It was nice for translating out of GLSL
IR (which also does that) but cumbersome the rest of the time.
---
src/glsl/nir/glsl_to_nir.cpp | 5 ++-
src/glsl/nir/nir.c| 6 +--
src/glsl/nir/nir.h| 4 +-
---
src/glsl/list.h | 9 +
1 file changed, 9 insertions(+)
diff --git a/src/glsl/list.h b/src/glsl/list.h
index 4774ccc..330c17e 100644
--- a/src/glsl/list.h
+++ b/src/glsl/list.h
@@ -678,4 +678,13 @@ inline void exec_node::insert_before(exec_list *before)
__node = __next, __next
This pass is still fairly basic. It only handles ALU operations, constant
loads, and phi nodes. No texture ops or intrinsics yet.
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_opt_cse.c | 269 +
3 files ch
---
src/glsl/nir/nir.c | 18 ++
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 060359a..32473e0 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1732,22 +1732,24 @@ static inline bool
foreach_if(nir_if *if_s
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 31 ++-
1 file changed, 18 insertions(+), 13 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index b6720af..5703225 100644
--- a/src/mesa/drivers/dri/i965/brw_
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 019d649..f4656bc 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++ b/src/mesa/drivers/
---
src/glsl/Makefile.sources| 1 +
src/glsl/nir/nir.h | 1 +
src/glsl/nir/nir_opcodes.h | 1 +
src/glsl/nir/nir_opt_peephole_ffma.c | 191 +++
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 2 +
5 files change
---
src/glsl/nir/nir_validate.c | 41 +
1 file changed, 41 insertions(+)
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c
index ae8deb8..727f141 100644
--- a/src/glsl/nir/nir_validate.c
+++ b/src/glsl/nir/nir_validate.c
@@ -49,6 +49,9
---
src/mesa/drivers/dri/i965/brw_fs.h | 4 +--
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 46 +++-
src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 5 +--
3 files changed, 30 insertions(+), 25 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs.h
b/s
---
src/glsl/nir/nir.c | 61 ++
src/glsl/nir/nir.h | 1 +
2 files changed, 62 insertions(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 1566e7c..5d7d21a 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1677,6 +1677,67
---
src/glsl/nir/nir.c | 25 +++--
1 file changed, 23 insertions(+), 2 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 32473e0..1566e7c 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -724,6 +724,23 @@ split_block_beginning(nir_block *block)
Since we don't actually have an "if" instruction, this is a very common
pattern when iterating over instructions. This adds a helper function for
it to make things a little less painful.
---
src/glsl/nir/nir.c | 17 +
src/glsl/nir/nir.h | 5 +
src/glsl/nir/n
Previously, emit_general_interpolation took an ir_variable and pulled the
information it needed from that. This meant that in fs_fp, we were
constructing a dummy ir_variable just to pass into it. This commit makes
emit_general_interpolation take only the information it needs and gets rid
of the f
The unlink_blocks function moves successors around to make sure that, if
there is a remaining successor, it is in the first successors slot and not
the second. To fix this, we simply get both successors up front.
---
src/glsl/nir/nir.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff
---
src/glsl/nir/nir.c| 16 +---
src/glsl/nir/nir_to_ssa.c | 16 +---
2 files changed, 6 insertions(+), 26 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 8c734fc..f30d75a 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1138,12
We also make the return types match GLSL. The GLSL spec specifies that
findMSB and findLSB return a signed integer. Previously, nir had them
return unsigned. This updates nir's behavior to match what GLSL expects.
We also update the nir-to-fs generator to take the new instructions. While
we're
---
src/glsl/nir/nir.c | 27 +++
src/glsl/nir/nir.h | 2 ++
2 files changed, 29 insertions(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index d3fd084..f7bee9d 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1628,6 +1628,33 @@ nir_foreach_src(nir_in
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_opt_peephole_select.c | 214 +
3 files changed, 217 insertions(+)
create mode 100644 src/glsl/nir/nir_opt_peephole_select.c
diff --git a/src/glsl/M
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 23 +++
1 file changed, 15 insertions(+), 8 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 561c709..d7a2d0b 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cp
---
src/glsl/nir/nir_validate.c | 13 +
1 file changed, 13 insertions(+)
diff --git a/src/glsl/nir/nir_validate.c b/src/glsl/nir/nir_validate.c
index 200c85a..ae8deb8 100644
--- a/src/glsl/nir/nir_validate.c
+++ b/src/glsl/nir/nir_validate.c
@@ -452,6 +452,7 @@ validate_phi_src(nir_ph
---
src/glsl/nir/nir.c| 14 ++
src/glsl/nir/nir.h| 4
src/glsl/nir/nir_to_ssa.c | 28 +++-
3 files changed, 25 insertions(+), 21 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 2c06d7e..8c734fc 100644
--- a/src/glsl
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index d7a2d0b..b2c5863 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++ b/src/mesa/drivers/dri/i965/brw_f
---
src/glsl/nir/nir_from_ssa.c | 40 -
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 50 +---
2 files changed, 65 insertions(+), 25 deletions(-)
diff --git a/src/glsl/nir/nir_from_ssa.c b/src/glsl/nir/nir_from_ssa.c
index 62a54fe..931
This pass is kind of stupidly implemented but it should be enough to get us
up and going. We probably want something better that doesn't generate all
of the redundant moves eventually. However, the i965 backend should be
able to handle the movs, so I'm not too worried about it in the short term.
Because NIR is typeless, it treats all constants as uint32 values and
reinterprets them when they are used later. This commit allows those
values to be properly propagated.
---
src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --
---
src/glsl/nir/nir.c | 45 -
src/glsl/nir/nir.h | 23 +++
src/glsl/nir/nir_print.c | 21 +
3 files changed, 88 insertions(+), 1 deletion(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index
---
src/glsl/Makefile.sources | 1 +
src/glsl/nir/nir.h| 13 ++
src/glsl/nir/nir_live_variables.c | 282 ++
src/glsl/nir/nir_metadata.c | 2 +
src/mesa/main/bitset.h| 1 +
5 files changed, 299 insertions(+)
creat
---
src/glsl/nir/nir.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 3c897b2..a12c209 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1654,9 +1654,7 @@ nir_foreach_block(nir_function_impl *impl,
nir_foreach_block_
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 9 +
1 file changed, 9 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index efe06d7..99094c7 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++ b/src/mesa/drivers/dri/i96
---
src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 17 ++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index 22f4c0f..677bd8f 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++
---
src/glsl/nir/nir.c | 54 ++
src/glsl/nir/nir.h | 1 +
2 files changed, 55 insertions(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index f30d75a..27e903e 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1599,6 +1599,60
---
src/glsl/nir/nir_intrinsics.h | 52 +--
1 file changed, 35 insertions(+), 17 deletions(-)
diff --git a/src/glsl/nir/nir_intrinsics.h b/src/glsl/nir/nir_intrinsics.h
index e82152c..e4ad8cd 100644
--- a/src/glsl/nir/nir_intrinsics.h
+++ b/src/glsl/nir/nir
---
src/glsl/nir/nir.c | 79 +-
1 file changed, 54 insertions(+), 25 deletions(-)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index a12c209..5dbcc77 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -1591,51 +1591,65 @@ nir_fo
---
src/glsl/nir/nir_opcodes.h| 6 +++---
src/glsl/nir/nir_opt_copy_propagate.c | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/glsl/nir/nir_opcodes.h b/src/glsl/nir/nir_opcodes.h
index 36a50d7..bee4bd1 100644
--- a/src/glsl/nir/nir_opcodes.h
+++ b/src/glsl/n
Some time while refactoring things to make it look nicer before pushing to
master, I completely broke the function. This fixes it to be correct.
Just goes to show you why you souldn't push code that has no users yet...
Signed-off-by: Jason Ekstrand
---
src/glsl/list.h | 4 +---
1 file changed,
---
src/glsl/Makefile.sources| 1 +
src/glsl/nir/nir.h | 2 +
src/glsl/nir/nir_lower_vec_to_movs.c | 96
3 files changed, 99 insertions(+)
create mode 100644 src/glsl/nir/nir_lower_vec_to_movs.c
diff --git a/src/glsl/Makefile.s
These indices should now be reasonably stable/consistent. Redoing the
indices in the print functions makes it harder to debug problems.
---
src/glsl/nir/nir_print.c | 4
1 file changed, 4 deletions(-)
diff --git a/src/glsl/nir/nir_print.c b/src/glsl/nir/nir_print.c
index 0140f4e..dd57116 10
---
src/glsl/nir/nir.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
index 0124799..3c897b2 100644
--- a/src/glsl/nir/nir.c
+++ b/src/glsl/nir/nir.c
@@ -840,6 +840,7 @@ handle_jump(nir_block *block)
unlink_blocks(last_block, after_block);
---
src/glsl/nir/glsl_to_nir.cpp | 5 +
1 file changed, 5 insertions(+)
diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp
index c4dff0d..60a24bc 100644
--- a/src/glsl/nir/glsl_to_nir.cpp
+++ b/src/glsl/nir/glsl_to_nir.cpp
@@ -1012,6 +1012,11 @@ nir_visitor::visit(ir_exp
---
src/glsl/Makefile.sources| 1 +
src/glsl/nir/nir.c | 19 +++-
src/glsl/nir/nir.h | 21 --
src/glsl/nir/nir_dominance.c | 6 ++---
src/glsl/nir/nir_metadata.c | 52
5 files changed, 82 insertions
---
src/glsl/nir/nir_lower_variables_scalar.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/glsl/nir/nir_lower_variables_scalar.c
b/src/glsl/nir/nir_lower_variables_scalar.c
index 52e1ce6..92b716a 100644
--- a/src/glsl/nir/nir_lower_variables_scalar.c
+++ b/src/glsl/nir/nir_lower_vari
1 - 100 of 245 matches
Mail list logo