Go to file
Ulrich Weigand 1931b01a64 [PowerPC] Remove incorrect use of COPY_TO_REGCLASS in fast isel
The fast isel pass currently emits a COPY_TO_REGCLASS node to convert
from a F4RC to a F8RC register class during conversion of a
floating-point number to integer. There is actually no support in the
common code instruction printers to emit COPY_TO_REGCLASS nodes, so the
PowerPC back-end has special code there to simply ignore
COPY_TO_REGCLASS.

This is correct *if and only if* the source and destination registers of
COPY_TO_REGCLASS are the same (except for the different register class).
But nothing guarantees this to be the case, and if the register
allocator does end up allocating source and destination to different
registers after all, the back-end simply generates incorrect code. I've
included a test case that shows such incorrect code generation.

However, it seems that COPY_TO_REGCLASS is actually not intended to be
used at the MI layer at all. It is used during SelectionDAG, but always
lowered to a plain COPY before emitting MI. Other back-end's fast isel
passes never emit COPY_TO_REGCLASS at all. I suspect it is simply wrong
for the PowerPC back-end to emit it here.

This patch changes the PowerPC back-end to directly emit COPY instead of
COPY_TO_REGCLASS and removes the special handling in the instruction
printers.

Differential Revision: http://reviews.llvm.org/D18605

llvm-svn: 265020
2016-03-31 14:44:50 +00:00
clang [OpenCL] Added nosvm attribute for OpenCL v2.0. 2016-03-31 11:07:22 +00:00
clang-tools-extra [docs] Fix a typo, change the style of the clang-tidy release notes a bit. 2016-03-31 12:06:54 +00:00
compiler-rt Update copyright year to 2016. 2016-03-30 22:38:50 +00:00
debuginfo-tests New round of fixes for "Always compile debuginfo-tests for the host triple" 2014-10-18 23:47:59 +00:00
libclc Update copyright year to 2016. 2016-03-30 22:39:03 +00:00
libcxx Fix LWG issue 2469 - Use piecewise construction in map::operator[]. 2016-03-31 03:13:37 +00:00
libcxxabi Update copyright year to 2016. 2016-03-30 22:40:47 +00:00
libunwind [AArch64] Fix libunwind build when using GNU assembler 2016-02-11 21:22:57 +00:00
lld Pass a const SymbolBody to needsGot. NFC. 2016-03-31 13:38:28 +00:00
lldb Don't vary debug info for lldb-server tests 2016-03-31 14:22:52 +00:00
llgo [llgo] add USES_TERMINAL option to check-libgo 2016-03-30 00:29:33 +00:00
llvm [PowerPC] Remove incorrect use of COPY_TO_REGCLASS in fast isel 2016-03-31 14:44:50 +00:00
openmp Fix bug when KMP_USE_ADAPTIVE_LOCKS is 0 2016-03-30 21:50:59 +00:00
polly Update copyright year to 2016. 2016-03-30 22:41:38 +00:00