[PATCH] D26114: [AMDGPU] Allow hoisting of comparisons out of a loop and eliminate condition copies
Stanislav Mekhanoshin via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 3 10:09:42 PDT 2016
rampitec added inline comments.
================
Comment at: lib/Target/AMDGPU/SILowerI1Copies.cpp:133
+ MachineInstr *Use = RegUses.pop_back_val();
+ if (Use->getOperand(1).getReg() == Dst.getReg()) {
+ unsigned FromReg = Use->getOperand(0).getReg();
----------------
vpykhtin wrote:
> if we already know that Use is a copy and it uses Dst why it's needed to check that Operand(1) is Dst? Maybe assert is enough here.
I'm changing registers in this loop and after the initial use list collection. This is to be on the safe side to check it still uses the same register.
Repository:
rL LLVM
https://reviews.llvm.org/D26114
More information about the llvm-commits
mailing list