[PATCH] D20649: [X86] Add a pattern that uses GR16_ABCD rather than GR32_ABCD to avoid falsely marking whole 32 bit register as live.
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Thu May 26 11:30:01 PDT 2016
MatzeB added a comment.
In http://reviews.llvm.org/D20649#440928, @spatel wrote:
> [cc'ing Matthias, Mitch, Quentin ; a related test suggestion was made in http://reviews.llvm.org/D20456]
> The code change itself looks fine to me, but I wonder if there's a preference for the test case to use "-stop-after" instead (similar to how MIR tests are written):
> ; RUN: llc -march=x86 -stop-after=expand-isel-pseudos <%s 2>&1 | FileCheck %s
> And then either CHECK for the exact expected sequence of machine instructions or CHECK-NOT the instructions that are generated without the patch:
> %5 = INSERT_SUBREG %6, %0, 3
> %7 = COPY %5
In an ideal world the -print-after output and .mir files would look the same. Today I would have a preference to match against the .mir output rather than the -print-machineinstrs output. However in this specific case you run into a shortcoming of .mir: The subregister indexes are printed as numbers rather than their name in the .mir output. So I'd probably keep matching -print-after until this is fixed.
More information about the llvm-commits