Issue 114903
Summary wrong overflow flag in correlated propagation
Labels new issue
Assignees
Reporter bongjunj
    
Alive2 report: https://alive2.llvm.org/ce/z/d3WhhS

```llvm
----------------------------------------
define i32 @and_sel_op0.2(i1 %b) {
#0:
  %s = select i1 %b, i32 25, i32 undef
  %#2 = mul i32 %s, 65535
  %#3 = select i1 %b, i32 %s, i32 %#2
  ret i32 %#3
}
=>
define i32 @and_sel_op0.2(i1 %b) {
#0:
  %s = select i1 %b, i32 25, i32 undef
  %#2 = mul nsw nuw i32 %s, 65535
  %#3 = select i1 %b, i32 %s, i32 %#2
  ret i32 %#3
}
Transformation doesn't verify!

ERROR: Target is more poisonous than source

Example:
i1 %b = #x0 (0)

Source:
i32 %s = #x00000000 (0)	[based on undef value]
i32 %#2 = #x00000000 (0)
i32 %#3 = #x00000000 (0)

Target:
i32 %s = #x10806000 (276848640)
i32 %#2 = poison
i32 %#3 = poison
Source value: #x00000000 (0)
Target value: poison

Summary:
  0 correct transformations
  1 incorrect transformations
  0 failed-to-prove transformations
  0 Alive2 errors
```
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to