14:15 haasn: can ACO optimize max(max(...max(max(max(a,b),c),d),e),...z) into max(max(max(a,b), max(c,d)), max(max(e,f), ...)))?
14:15 haasn: (I'm generating code with the former structure)
14:16 pendingchaos: it probably can, but I don't think it does
14:28 haasn: hrm, it will be annoying to refactor my process to generate a proper binary tree here, but maybe I should test to see if it will help perf
14:28 haasn: (I'm only max'ing 12 values though, so maybe it's not so big a deal)
14:34 Venemo: haasn: something like that, belongs to nir_opt_algebraic in my opinion
15:41 haasn: hardware can do conversion from sRGB to linear RGB during sampling, including when linear filtering
15:41 haasn: can it do the reverse, i.e. conversion from linear RGB to sRGB during sampling (and interpolating in sRGB space)?
15:44 pendingchaos: no
19:57 mareko: a properly balanced expression tree of associative opcodes like min/max would be interesting for instruction-level parallelism, but not so much for register usage, and nir_algebraic would have to learn how to compute the expression depth to balance it properly
19:58 haasn: (in the end I scrapped the approach anyway, so it's not a big deal)
19:58 haasn: I wonder if something similar would be helpful for a + b + c + d + e
19:58 haasn: (((a + b) + c) + d) + e vs ((a + b) + (c + d)) + e
19:59 mareko: it would definitely be interesting to benchmark