bisected to fb2269fed16cf804f5b7538537ec6d53ed1e20c9 Author: Timothy Arceri <timothy.arceri@collabora.com> nir: shuffle constants to the top Standard Output Statement: 1 Reference definitions: float dot(float a, float b) { return (a * b); } float reflect(float a, float b) { float dotNI0 = dot(b, a); return (a - {((b * dotNI0) * 2) | (b * (dotNI0 * 2))}); } Failed sample: in0 = -0x1.fffffep127 in1 = 0.0 out0 = NaN Expected range: { -0x1.fffffep127 } Failed sample: in0 = -0x1.fffffep127 in1 = -0x0.000002p-126 out0 = NaN Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = -0x0.fffffep-126 out0 = NaN Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = -0x1.000000p-126 out0 = +inf Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = -0x1.000002p-126 out0 = +inf Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = -0x1.000000p-1 out0 = +inf Expected range: { -0x1.fffffep126 } Failed sample: in0 = -0x1.fffffep127 in1 = 0x0.000002p-126 out0 = NaN Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = 0x0.fffffep-126 out0 = NaN Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = 0x1.000000p-126 out0 = +inf Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = 0x1.000002p-126 out0 = +inf Expected range: [-0x1.fffffep127, -0x1.fffffcp127] Failed sample: in0 = -0x1.fffffep127 in1 = 0x1.000000p-1 out0 = +inf Expected range: { -0x1.fffffep126 } Failed sample: in0 = 0x1.fffffep127 in1 = 0.0 out0 = NaN Expected range: { 0x1.fffffep127 } Failed sample: in0 = 0x1.fffffep127 in1 = -0x0.000002p-126 out0 = NaN Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = -0x0.fffffep-126 out0 = NaN Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = -0x1.000000p-126 out0 = -inf Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = -0x1.000002p-126 out0 = -inf Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = -0x1.000000p-1 out0 = -inf Expected range: { 0x1.fffffep126 } Failed sample: in0 = 0x1.fffffep127 in1 = 0x0.000002p-126 out0 = NaN Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = 0x0.fffffep-126 out0 = NaN Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = 0x1.000000p-126 out0 = -inf Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = 0x1.000002p-126 out0 = -inf Expected range: [0x1.fffffcp127, 0x1.fffffep127] Failed sample: in0 = 0x1.fffffep127 in1 = 0x1.000000p-1 out0 = -inf Expected range: { 0x1.fffffep126 } Failed sample: in0 = 0x1.34ac12p127 in1 = 0x1.57b790p-23 out0 = -inf Expected range: [0x1.34ac10p127, 0x1.34ac12p127] Failed sample: in0 = 0x1.d9d14cp127 in1 = 0x1.fffffep-40 out0 = -inf Expected range: [0x1.d9d14ap127, 0x1.d9d14cp127] Failed sample: in0 = 0x1.2c2ba2p127 in1 = -0x1.0f68fcp-51 out0 = -inf Expected range: [0x1.2c2ba0p127, 0x1.2c2ba2p127] Failed sample: in0 = 0x1.e8a18cp127 in1 = 0x1.de8a0ep-105 out0 = -inf Expected range: [0x1.e8a18ap127, 0x1.e8a18cp127] Failed sample: in0 = 0x1.9e6bccp127 in1 = 0x1.000002p-57 out0 = -inf Expected range: [0x1.9e6bcap127, 0x1.9e6bccp127] 27/16662 inputs failed.
Sorry I've been seeing lots of VK tests failing seemingly randomly in my jenkins results so I probably dismissed this failure as one of those. As far as I can tell this isn't a bug with the commit itself, the optimisations are marked as imprecise. My guess is the precision qualifier is getting lost or is not applied correctly.
Hi Tim, Despite the name, this isn't a precise keyword test. It's just verifying that reflect() works with various floating point values. The test does "out = reflect(in0, in1)". It looks like before we generated: ffma -2.0 (mul (mul ssbo10 ssbo13) ssbo13) ssbo10 And now we generate: ffma (mul (mul ssbo10 2.0) ssbo13) ssbo13 ssbo10 which is having trouble with some extreme values. CC'ing Jason too.
Modulo the -2.0 -> 2.0 change which I'll assume is a typo, that looks like it should be correct. It's very odd that it returns NaN. I could see a flush to infinity but NaN is weird. Does MAD not handle +-inf correctly?
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/1591.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.