The copy operation with a predicated dependency is currently
marked with an implicit operand. It is good to have a separate
opcode for such instances to distinguish them from the regular
copies that have no dependencies at all. This will allow targets
more control while lowering the copies. AMDGPU, for instance,
have the implicit dependency with exec register for all vector
copies and no such dependency for scalar copies and there is a
custom pass currently adds the implicit exec operand to every
vector copy and that doesn't look right.
This patch introduces a new opcode PRED_COPY, called the
predicated equivalent of the existing COPY opcode. Targets
can define the default copy opcode and the getCopyOpcode
callback would return the chosen opcode appropriately. Every
interface that needs TargetOpcode::COPY should now be replaced
with a call to getCopyOpcode. Targets have the control over how
and when to lower the PRED_COPY instructions.
So what is the result when the predicate is false?.
(That kind of question does not exist for any existing generic opcodes afaik, because this would be the first predicable generic opcode.)