aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorJuergen Ributzka <juergen@apple.com>2013-11-13 01:57:54 +0000
committerJuergen Ributzka <juergen@apple.com>2013-11-13 01:57:54 +0000
commit34c652d34de123f1771f5a354f781a8e101e8937 (patch)
tree98240fa9391fa5836b82f478ab5ef84eb5e20acb /clang/lib/Frontend/CompilerInvocation.cpp
parenta477d2ab572fe49ad65c80dcfdc64ad1bd133b74 (diff)
downloadllvm-34c652d34de123f1771f5a354f781a8e101e8937.zip
llvm-34c652d34de123f1771f5a354f781a8e101e8937.tar.gz
llvm-34c652d34de123f1771f5a354f781a8e101e8937.tar.bz2
SelectionDAG: Teach the legalizer to split SETCC if VSELECT needs splitting too.
This patch reapplies r193676 with an additional fix for the Hexagon backend. The SystemZ backend has already been fixed by r194148. The Type Legalizer recognizes that VSELECT needs to be split, because the type is to wide for the given target. The same does not always apply to SETCC, because less space is required to encode the result of a comparison. As a result VSELECT is split and SETCC is unrolled into scalar comparisons. This commit fixes the issue by checking for VSELECT-SETCC patterns in the DAG Combiner. If a matching pattern is found, then the result mask of SETCC is promoted to the expected vector mask type for the given target. Now the type legalizer will split both VSELECT and SETCC. This allows the following X86 DAG Combine code to sucessfully detect the MIN/MAX pattern. This fixes PR16695, PR17002, and <rdar://problem/14594431>. Reviewed by Nadav llvm-svn: 194542
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions