DirectXShaderCompiler/test/HLSL/passes
David Neto d324261642
Reassociation: fix counting of constant multiplicative factors (#6830)
In the middle of rewriting expressions like (A*B + A*C + D) to pull
common factor A out, the algorithm finds that there's actually only one
A. This is unexpected, and it fires an assertion.

This can occur when A is a constant, and constant -A also appears in the
terms somewhere else.

There is no harm in this situation, however, because the algorithm then
creates an addition-tree, but with a single element, and that's still
correct.

This bookkeeping issue was fixed later in LLVM, at
95abfa35d6

Unfortunately the associated test doesn't translate cleanly to DXC-era
LLVM. I've added test case reduced from our original case.

Fixed: #6829
2024-08-01 11:41:05 -04:00
..
dxil_o0_legalize [bug] Fix crash in dxilgen when buffer subscript gep feeds an lcssa phi (#5570) 2023-08-25 05:54:10 +00:00
dxil_remove_unstructured_loop_exits Remove unstructured loop exits: Don't introduce loops (#6676) 2024-06-14 09:43:50 -04:00
dxilgen [bug] Fix crash in dxilgen when buffer subscript gep feeds an lcssa phi (#5570) 2023-08-25 05:54:10 +00:00
indvars indvars: don't replace a phi when that breaks LCSSA (#6695) 2024-06-17 20:56:16 -04:00
instcombine [Instcombine] Disable bswap match for DXIL (#5899) 2023-10-20 13:31:00 -05:00
multi_dim_one_dim [bug] Fix crash when lowering multi-dimension groupshared variable (#5895) 2023-10-23 11:00:36 -07:00
reassociate Reassociation: fix counting of constant multiplicative factors (#6830) 2024-08-01 11:41:05 -04:00