[PATCH] D64713: [InstCombine] X *fast (C ? 1.0 : 0.0) -> C ? X : 0.0

Dávid Bolvanský via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 15 03:26:13 PDT 2019


xbolva00 added inline comments.


================
Comment at: llvm/lib/Transforms/InstCombine/InstructionCombining.cpp:782
+      SI = Builder.CreateSelect(A, Builder.CreateBinOp(Opcode, B, E), V1);
+  } else if (LHSIsSelect) {
+    // (A ? B : C) op Y -> A ? (B op Y) : (C op Y)
----------------
Can you simplify lines 782-808? Almost same code in both branches..


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D64713/new/

https://reviews.llvm.org/D64713





More information about the llvm-commits mailing list