[MCA][InstrBuilder] Check for the presence of flag VariadicOpsAreDefs.
authorAndrea Di Biagio <andrea.dibiagio@sony.com>
Mon, 14 Jun 2021 23:52:16 +0000 (00:52 +0100)
committerAndrea Di Biagio <andrea.dibiagio@sony.com>
Tue, 15 Jun 2021 08:52:38 +0000 (09:52 +0100)
commitbeb5213a2ee56bbf554ccdd1908c48d10e244dab
tree2e08056bd91c61bfb4aeb73adf6c81f0d836fdd3
parent13f0b85212275fb6f724b14c2c5385385e5e723f
[MCA][InstrBuilder] Check for the presence of flag VariadicOpsAreDefs.

This patch fixes the logic that checks for variadic register definitions,

Before llvm-svn 348114 (commit 4cf35b4ab0b), it was not possible to explicitly
mark variadic operands as definitions. By default, variadic operands of an
MCInst were always assumed to be uses. A number of had-hoc checks were
introduced in the InstrBuilder to fix the processing of variadic register
operands of ARM ldm/stm variants.

This patch simply replaces those old (and buggy) checks with a much simpler (and
correct) check for MCID::Flag::VariadicOpsAreDefs.
llvm/lib/MCA/InstrBuilder.cpp
llvm/test/tools/llvm-mca/ARM/cortex-a57-carryover.s