[PATCH] D73410: [InstCombine] Push negation through multiply (PR44234)
Dávid Bolvanský via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 27 12:53:12 PST 2020
xbolva00 added a comment.
Thanks on working on this
================
Comment at: llvm/lib/Transforms/InstCombine/InstructionCombining.cpp:940
+ // 0-(A*B) => A*(0-B)
+ case Instruction::Mul:
+ if (Value *NegA = freelyNegateValue(I->getOperand(0)))
----------------
Not related to this change:
Should we worry about recursion depth here? Probably not a issue in practise..
================
Comment at: llvm/test/Transforms/InstCombine/sub.ll:702
define i64 @test_neg_mul_sub_communted(i64 %a, i64 %b, i64 %c) {
; CHECK-LABEL: @test_neg_mul_sub_communted(
----------------
commuted
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73410/new/
https://reviews.llvm.org/D73410
More information about the llvm-commits
mailing list