We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
See, for example:
$ opt -div-rem-pairs Transforms/DivRemPairs/X86/div-rem-pairs.ll
define void @decompose_illegal_srem_same_block(i32 %a, i32 %b) { %rem = srem i32 %a, %b %div = sdiv i32 %a, %b call void @foo(i32 %rem, i32 %div) ret void } => define void @decompose_illegal_srem_same_block(i32 %a, i32 %b) { %div = sdiv i32 %a, %b %1 = mul i32 %div, %b %2 = sub i32 %a, %1 call void @foo(i32 %2, i32 %div) ret void } Transformation doesn't verify! ERROR: Source is more defined than target
Example: i32 %a = undef i32 %b = #x00000001 (1)
Source: i32 %rem = #x00000000 (0) i32 %div = undef
Target: i32 %div = #x7fffffff (2147483647) i32 %1 = undef i32 %2 = undef
The text was updated successfully, but these errors were encountered:
Fix proposed here: https://reviews.llvm.org/D76483
Sorry, something went wrong.
mentioned in issue llvm/llvm-bugzilla-archive#45885
mentioned in issue #47292
No branches or pull requests
Extended Description
See, for example:
$ opt -div-rem-pairs Transforms/DivRemPairs/X86/div-rem-pairs.ll
define void @decompose_illegal_srem_same_block(i32 %a, i32 %b) {
%rem = srem i32 %a, %b
%div = sdiv i32 %a, %b
call void @foo(i32 %rem, i32 %div)
ret void
}
=>
define void @decompose_illegal_srem_same_block(i32 %a, i32 %b) {
%div = sdiv i32 %a, %b
%1 = mul i32 %div, %b
%2 = sub i32 %a, %1
call void @foo(i32 %2, i32 %div)
ret void
}
Transformation doesn't verify!
ERROR: Source is more defined than target
Example:
i32 %a = undef
i32 %b = #x00000001 (1)
Source:
i32 %rem = #x00000000 (0)
i32 %div = undef
Target:
i32 %div = #x7fffffff (2147483647)
i32 %1 = undef
i32 %2 = undef
The text was updated successfully, but these errors were encountered: